WHERE clause on the command line is not supported
Database Subsetter and Relational Data Browser
Brought to you by:
rwisser
When I want to extract an extraction model over command line, the extraction works as long as I don't use a where clause. At the moment I type a where clause, it acts like I've put a wrong parameter and prints out the help. Even if I copy and paste the command line as I get it in the export dialog of the GUI. The same where clause works well with the GUI. I used the parameter as described:
jailer.sh extract ... -where 'field = 3' ...
I tried this with 9.1.1 and also the latest version of jailer.
A.T.
Anonymous
Sorry, the parameter "extract" should be "export" of course.
I can not reproduce the error. Are you sure the shell does not do any character substitutions?
What does this give?
echo jailer.sh export -where ...I found out, that the parameter where works but in the where clause itself should be no blanks. This means that the following statement will not work:
But if you write it without spaces, it works:
I'm using Linux and execute jailer from a bash shell.
A.T.
That's strange. The arguments should not be split if they are in quotation marks. ( because in
jailer.shthe parameter passing takes place via"$@")Are you sure that a bash is used and no other shell?
I think I found the error. I installed jailer in the directory
/usr/local/jailerby unzipping the ZIP file. Then I created in the directory/usr/local/bina small wrapper script to be able to call jailer with it's full path. This saved me the need to change my PATH environment variable.As you can see, I forgot the quotes around the
$@and this caused the problem. The problem was my fault. Sorry to bother you with it.A.T.
No problem. Shell scripting is sometimes tricky.