Difference between revisions of "Command-Line Options"

From BaseX Documentation
Jump to navigation Jump to search
(Created page with "==BaseX Server== If you want to interact (execute commands, add databases, add users) with the server, start the server with the <code>-i</code> flag. :<code> > java -cp BaseX....")
 
Line 25: Line 25:
 
<pre>BaseX [Server]
 
<pre>BaseX [Server]
 
Server was started.</pre>
 
Server was started.</pre>
 +
 +
==BaseX Client==
 +
 +
All available command-line flags can be listed by adding <code>-h</code> to the call:
 +
:<code>
 +
java -cp BaseX.jar org.basex.BaseXClient -h
 +
</code>
 +
<pre>
 +
Usage: BaseXClient [-npPU] [-dovVwz] [-cq] [file]
 +
  [file]    Execute XQuery file
 +
  -c<cmd>    Execute database command(s)
 +
  -d        Activate debugging mode
 +
  -n<name>  Set server (host) name
 +
  -o<file>  Write output to file
 +
  -p<num>    Set server port
 +
  -P<pass>  Specify user password
 +
  -q<expr>  Execute XQuery expression
 +
  -U<name>  Specify user name
 +
  -v/V      Show (all) process info
 +
  -w        Keep whitespaces from source files
 +
  -z        Skip output of results
 +
</pre>
  
 
==BaseX Standalone==
 
==BaseX Standalone==

Revision as of 11:25, 12 January 2011

BaseX Server

If you want to interact (execute commands, add databases, add users) with the server, start the server with the -i flag.

> java -cp BaseX.jar org.basex.BaseXServer -i

All available command-line flags can be listed by adding -h to the call:

> java -cp BaseX.jar org.basex.BaseXServer -h

Usage: BaseXServer [-s] [-dpz] [-c] [stop]
  stop     Stop existing server
  -c<cmd>  Execute initial database command(s)
  -d       Activate debugging mode
  -i       Enter interactive mode
  -p<num>  Set server port
  -s       Start as service
  -z       Suppress logging

If the server is succesfully started, this is coming up:

BaseX [Server]
Server was started.

BaseX Client

All available command-line flags can be listed by adding -h to the call:

java -cp BaseX.jar org.basex.BaseXClient -h

Usage: BaseXClient [-npPU] [-dovVwz] [-cq] [file]
  [file]     Execute XQuery file
  -c<cmd>    Execute database command(s)
  -d         Activate debugging mode
  -n<name>   Set server (host) name
  -o<file>   Write output to file
  -p<num>    Set server port
  -P<pass>   Specify user password
  -q<expr>   Execute XQuery expression
  -U<name>   Specify user name
  -v/V       Show (all) process info
  -w         Keep whitespaces from source files
  -z         Skip output of results

BaseX Standalone