> I have no probs when using idbroker. When I change it to native, rebuild > and run the pogram I get the following exception: Do you mean you have recreated the om files? If not, you will have to do that.
> And if I use native do I > still need the ID_TABLE? No you do not need ID_TABLE when u use native. HTH > -----Original Message----- > From: Sergey Moiseyev [mailto:[EMAIL PROTECTED] > Sent: Thursday, October 23, 2003 11:11 AM > To: [EMAIL PROTECTED] > Subject: Using native id method for MySQL > > Hello > > I have problem inserting data in to the tables when using database > attribute > > defautIdMethod = "native". > > I am using torque-3.0. > I have no probs when using idbroker. When I change it to native, rebuild > and run the pogram I get the following exception: > > org.apache.torque.TorqueException: IdGenerator for table 'frm_category' > is null > at org.apache.torque.util.BasePeer.doInsert(BasePeer.java:690) > at > com.peoplelogic.db.BaseFrmCategoryPeer.doInsert(BaseFrmCategoryPeer.java :2 > 16) > at > com.peoplelogic.db.BaseFrmCategoryPeer.doInsert(BaseFrmCategoryPeer.java :5 > 65) > at com.peoplelogic.db.BaseFrmCategory.save(BaseFrmCategory.java:508) > at com.peoplelogic.db.BaseFrmCategory.save(BaseFrmCategory.java:470) > at com.peoplelogic.db.BaseFrmCategory.save(BaseFrmCategory.java:450) > at > com.peoplelogic.test.TorqueTest.createFormCategories(TorqueTest.java:59) > at com.peoplelogic.test.TorqueTest.main(TorqueTest.java:43) > > All the tables created OK with autoincrement primary keys > This is my property file: > > log4j.category.org.apache.torque = ALL, org.apache.torque > log4j.appender.org.apache.torque = org.apache.log4j.FileAppender > log4j.appender.org.apache.torque.file = > ${torque.applicationRoot}/logs/torque.log > log4j.appender.org.apache.torque.layout = org.apache.log4j.PatternLayout > log4j.appender.org.apache.torque.layout.conversionPattern = %d [%t] %-5p > %c - %m%n > log4j.appender.org.apache.torque.append = false > > torque.database.default = sergey > torque.database.sergey.adapter = mysql > torque.database.sergey.driver = org.gjt.mm.mysql.Driver > torque.database.sergey.url = jdbc:mysql://192.168.1.3/sergey > torque.database.sergey.username = systems > torque.database.sergey.password = tunafish > > Note, thate I have set > > torque.database.sergey.adapter=mysql > > but I can't find corresponding adapter in the adapter package! Could it > be the problem? > > Could anyone help me to understand whats going on? And what is the > advantages of using native instad of idbroker. And if I use native do I > still need the ID_TABLE? > > Thanks, > > Sergey > > > --------------------------------------------------------------------- > 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
