Ahhhh. For some reason that didn't click with me. I love stupid mistakes, they are so easy to resolve.

Hilco Wijbenga wrote:

As you noticed, 'create-db' really only does the bare minimum to earn
its name. :-)

You need 'insert-sql' to create the tables and such. It will attempt to
execute your xyz-schema.sql file.

On Thu, 2005-10-13 at 11:16 -0400, Trey Long wrote:
Create-Db seems to be stopping short of it's full task, let me see if I can explain my problem. Also, if you experts out there see any other problems with my configuration or whatever else I send over, please give me advice.

I have torque deployed using ant and I am currently testing the process of going from MSSQL to MySql. I believe the 'ant create-db' is supposed to read the {projectname}-schema.xml and create the database via the connection properties in the build.properties file.

If I have everything right so far let's move on, the only think that it generates in the 'source\sql\create-db.sql' file is this:
drop database if exists torque;
create database torque;

Any ideas why it stops there? Ant doesn't seem to gripe about anything as far as I can tell either.
create-db-check:

create-db:
[torque-data-model] Using classpath
[torque-data-model] Generating to file *path*\trunk\source\sql\create-db.sql
[torque-data-model] Oct 13, 2005 11:02:46 AM org.apache.torque.engine.database.transform.XmlToAppData parseFile
[torque-data-model] INFO: Parsing file: 'test-schema.xml'
[torque-data-model] Oct 13, 2005 11:02:46 AM org.apache.torque.engine.database.transform.DTDResolver resolveEntity [torque-data-model] INFO: Resolver: used database.dtd from 'org.apache.torque.engine.database.transform' package
    [echo]
    [echo]       Executing the create-db.sql script ...
    [echo]
     [sql] Executing file: *path*\trunk\source\sql\create-db.sql
     [sql] 2 of 2 SQL statements executed successfully

BUILD SUCCESSFUL
Total time: 3 seconds


And the config file seems ok to me.
torque.project = test
#MYSQL SECTION
torque.database = mysql
torque.database.type = mysql
torque.database.adaptor = mysql
torque.targetPackage = com.provima.pcsw.mysql

torque.database.createUrl = jdbc:mysql://localhost/test
torque.database.buildUrl = jdbc:mysql://localhost/test
torque.database.driver = org.gjt.mm.mysql.Driver
torque.database.user = root
torque.database.password = password
torque.database.host = localhost



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to