parse Queries In SQLScript
Method to parse a SQL script for the database. The script honors SQL comments and separates each SQL command into a list of strings, 1 string for each command. The list of queries is returned.
The script should have each command end in a semicolon, ; The best comment to use is #. All characters on a line after # will be stripped. Best to put # as the first character of a line with no further SQL on the line
Based on the work described here:
https://blog.heckel.xyz/2014/06/22/run-sql-scripts-from-java-on-hsqldb-derby-mysql/
Return
the list of strings of the commands
Parameters
file Path
a path to the file for parsing
Throws
if there is a problem