C-JDBC is now bundled with a graphical SQL console called Squirrel that you can launch fron the bin directory of the C-JDBC installation, using either squirrel.sh or squirrel.bat.You can also directly issue SQL statements from the virtual database console menu. The other commands available from the virtual database console menu are:
begin: Start a transaction
commit: Commit a transaction
fetchsize <x>: Set the ResultSet fetch size to x rows per block
help: Print this help message
history [<commandIndex>]: Display history of commands for this module
load <file name>: Execute all SQL statements contained in file
maxrows <x>: Limits the maximum number of rows to get from the database to x
quit: Quit this console
rollback [<savepoint name>]: Rollback a transaction (to an optional savepoint)
savepoint <savepoint name>: Create a savepoint for the current transaction
setisolation <x>: Set the connection transaction isolation level to x
0 - TRANSACTION_NONE
1 - TRANSACTION_READ_UNCOMMITTED
2 - TRANSACTION_READ_COMMITTED
4 - TRANSACTION_REPEATABLE_READ
8 - TRANSACTION_SERIALIZABLE
show tables: Display all the tables of this virtual database
timeout <x>: Set the query timeout to x seconds (default is 60 seconds)
{call proc_name(?,?,...)}: Call a stored procedure
Here is an example of a session with the virtual database console:
localhost:1090 > sql client jdbc:cjdbc://localhost/myDB > Login : user > Password : ****** Connected to jdbc:cjdbc://localhost/myDB jdbc:cjdbc://localhost/myDB (user) > begin Transaction started jdbc:cjdbc://localhost/myDB (user) > select * from regions ... result to be displayed here ... jdbc:cjdbc://localhost/myDB (user) > commit jdbc:cjdbc://localhost/myDB (user) > quit