Re: Help with mass import to MySQL using PHP

From: Date: Sat, 24 Feb 2001 19:30:50 +0000
Subject: Re: Help with mass import to MySQL using PHP
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-41504@lists.php.net to get a copy of this message
No answer, but a question. I noticed you're using, in effect, two id's for each entry, a id number and a doc id number. The first is accomplished thru auto-increment. Wouldn't it be easier to us just one id number, a=LAST_INSERT_ID(id+b) and reserve the first 10k numbers (b), whatever is needed for your old files then run a php code to format your old entries and increment those 1 - 100000....and forget about random numbers. If I'm not mistaken, if you generate random numbers you'll have to check, to be on the safe side, to make sure the random number wasn't used for someother doc. __________________________________________________ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/

« previous php.general (#41504) next »