Re: Overriding primary key field with DB_DataObject

From: Date: Sun, 21 Aug 2005 17:33:44 +0000
Subject: Re: Overriding primary key field with DB_DataObject
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-20509@lists.php.net to get a copy of this message
Justin Patrin wrote:
On 8/21/05, red <red@raven.ch> wrote:
Hi I'm trying to insert some entries in a table which will use auto_increment for id-assignement. But for the initial setup I need to write the entries including the key to maintain the relations. How can this be done with DataObjects?
You may be able to do it with the correct settings to sequenceKey().
Hm, thought about this, but since I'll need to set the ids only in one special case this is not an option.
I would suggest as an alternative you can create an initial database and dump it with mysqldump then import that.
Well, not really a solution since I have to automatically convert the data from an older database structure to the current one... However I'll do it without dataobjects. greets and thanks red -- http://raven.ch/ - red@raven.ch - icq: 33960605 Bahnhofstrasse 14 - 3400 Burgdorf - Switzerland Mobile: +41 76 373 70 20 - skype: syeo66 PGP-Key: http://raven.ch/public_key.asc

« previous php.pear.general (#20509) next »