Page 2 of 2

Re: create custom autonumber in mysql using php possibly?

Posted: Sun Feb 20, 2011 2:53 am
by McInfo
This last line is not a typo. It matches the parenthesis from line two and gives the sub-query a required alias.

Code: Select all

) `s`
This comma should not be here without additional fields.

Code: Select all

        ),
    
    FROM
Is IDNumber the only field in your table? Please, explain the theory of your system.

Re: create custom autonumber in mysql using php possibly?

Posted: Sun Feb 20, 2011 3:19 am
by cjkeane
i was merely trying to get the autonumber/PK to be generated properly on its own before adding in the rest of the fields to the script. i have a bunch of other fields such as firstname, lastname, address, phone, which all go into a records table along with the custom ID number.
.