mysql sequence emulation - problem
| From: | Wolfram Kriesing | Date: | Fri, 01 Feb 2002 16:59:52 +0000 |
| Subject: | mysql sequence emulation - problem | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-4333@lists.php.net to get a copy of this message | ||
i was using the mysql sequence emulation a lot of times and i
realized, that this extra table " *_seq " makes problems, whenever
you i.e. switch a table from using auto_increment to use the sequence
emulation, then you have to set the value in the table *_seq to the
proper value by hand
or
if you update an application to use sequences from now on, you have
to watch out, to set the sequence number properly by hand
why not simply select the "max" value from the table that the nextId
needs to be generated for and let the "nextId" return this "max value
+1" ?
what do you think??
or was there already a discussion in that, which i missed?
--
Wolfram