I have a table with, say, 2 columns, A and B. A will be filled with 1,2,3,4 etc (but not autogen, for the reason I'm about to give). In normal day-to-day activity, some records from the table can and will be removed, resulting in A containing 1,3,4,7,8, etc.
I'd like to write a little SQL function (mySQL) that will take the table and refill column A with an incrementing number, so 1,2,3,4,5 etc, depending on how many records there are.
I'd like to avoid using a temp table if possible as this is going to be a multi-user system and I need to get in there, change the details as quick as possible.
I apologise that this doesn't have much to do with php (just that I'm developing with php).