db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Manske, Michael" <Michael.Man...@dat.de>
Subject RE: newbie question
Date Wed, 06 Aug 2003 14:39:32 GMT
I believe to remember that there was an discussion about that issue on the
list some
time ago. As far as i remember it is an issue with the templates for mysql
and
it should work if you set idMethod="native" on database level too...

without any warranty,
Michael


> -----Original Message-----
> From: Mansour Raad [mailto:mraad@e-iit.com]
> Sent: Wednesday, August 06, 2003 2:07 AM
> To: torque-user@db.apache.org
> Subject: newbie question
> 
> 
> Hi,
> 
> If I define the idMethod as 'idbroker' in the table tag in 
> the schema.xml
> file, my test program works fine. However, when I switch it 
> to 'native' (as
> my db is mysql) my test program
> 
> produces:
> 
> org.apache.torque.TorqueException: IdGenerator for table 
> 'snapshot_head' is
> null at org.apache.torque.util.BasePeer.doInsert(BasePeer.java:690) at
> 
> com.npd.torque.BaseSnapshotHeadPeer.doInsert(BaseSnapshotHeadP
> eer.java:219)
> at
> 
> com.npd.torque.BaseSnapshotHeadPeer.doInsert(BaseSnapshotHeadP
> eer.java:569)
> at com.npd.torque.BaseSnapshotHead.save(BaseSnapshotHead.java:592)
> 
> at com.npd.torque.BaseSnapshotHead.save(BaseSnapshotHead.java:554)
> 
> at com.npd.torque.BaseSnapshotHead.save(BaseSnapshotHead.java:534)
> 
> at com.npd.torque.SnapshotHeadTest.main(SnapshotHeadTest.java:15)
> 
> Exception in thread "main" Process terminated with exit code 1
> 
> My question, is why is it still using the idGenerator, as MySQL has an
> autogeneration method !!! I'm missing something somewhere, 
> and have been
> staring at this for a while, any help will be appreciated !
> 
> Regards,
> 
> Mansour
> 
> ;-)
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message