Command-line utility to send SQL commands to a database.
This class is useful for creating a large number of database tables
and/or records from a user-defined text file containing SQL commands.
It relies on the
ConnectionPoolManager class to assist
with the creation of a connection to the database, which in turn requires
the appropriate
dbpool.properties file in the classpath.
Usage: java snaq.db.SQLUpdate <poolnames> <input file> [<separator>]
where
pool is the name of the connection pool as defined in
the
dbpool.properties file,
input file is the name of the text
file containing the SQL statements to be issued to the defined database,
and
separator is an optional parameter to specify a delimiter
for the SQL statements in the file. If the separator is not specified then
each line of the file is assumed to be a separate statement.
Note: comments are allowed in the input file by starting the line with
either "#" or "--".