November 12th, 2012, 12:58 PM
Primary key auto increment
I have a table called 'users' where there is a 'USRID' column that has been set as the primary key and is alphanumeric. We're working on another project and also need to have an auto increment numeric value unique to each record. I'm using navicat and when i try to add in the auto increment field and make a second key, each value of that field is 1, it doesn't increment. Any thoughts on how I could accomplish this?
November 12th, 2012, 01:07 PM
1. Use USRID instead
2. Make USRID UNIQUE instead of PRIMARY and use the auto_inc as the PRIMARY.
November 12th, 2012, 01:14 PM
thanks, i wasn't aware of the unique option.