General
Logging
Templates
Please look here
See our working example for instructions on testing SQL2JAVA with your database.
SQL2JAVA requires a relational database and the Java Runtime Engine, Java 1.4.0 or later.
These are just some of the databases currently working with SQL2JAVA.
Please contact us if you're using, or would like to use, SQL2JAVA with a database platform not listed here.
To add support for a new database or add retrieval of auto-generated keys for a new database, edit sql2java.properties.
If you'd like to help out, create a SourceForge user, look at the code, and send an email on the forum to be added to the project developer list.
Check http://www.p6spy.com/.
They provide a free jdbc driver that wraps the real jdbc driver and logs all you can dream of.
In your project.properties
please set the following properties:
jdbc.driver=com.p6spy.engine.spy.P6SpyDriver
jdbc.spydriver=org.hsqldb.jdbcDriver
Please go in your src/templates/ folder, look for the template you want to modify. ... and modify whatever needs to be modified to suits your needs.
You have 2 options, your template needs to be executed once per generation, then place your template in folder with a name called perschema in src/templates/. If you want your template to be executed for every table, call the folder pertable exemple:
src/templates/myplugin/perschema/mytemplate_for_each_schema.vm src/templates/myplugin/pertable/mytemplate_for_every_table.vm
You certainly have another file with the same filename in the template path described in sql2java.properties. Please rename your file, and there you go !
Please install http://www.research.att.com/sw/tools/graphviz/ in your C:/Program Files/ATT/Graphviz/ folder. If you are under unix, please update the following template to match your configuration src/templates/velocity/db/perschema/graphviz/ant.graphviz.xml.vm