Error running .sql via .bat

0

The query runs fine sqldeveloper but when calling via .bat does not recognize commands like ( case, nvl,sum ) Has anyone gone through this?

  'C: \ oracle \ app \ oracle \ product \ 11.2.0 \ server \ bin \ sqlplus.EXE @C: \ V1.sql'

    
asked by anonymous 03.07.2018 / 22:20

1 answer

0

Regarding errors in commands, it would not be the case for your bat to go in the path / folder where the application is run .

Do not just make a call to distance :

Pushd “C:\oraclexe\app\oracle\product.2.0\server\bin\” && sqlplus.EXE '@C:\V1.sql'

Or better yet, go there:

cd /d “C:\oraclexe\app\oracle\product.2.0\server\bin\” && sqlplus.EXE '@C:\V1.sql'
    
03.12.2018 / 11:13