MySQL ID
#1

Hello guys, I have a question about MySQL inserting. I'm creating a house system. In my create house command I need to set the house's ID, but the problem is that I don't know how to check the next id of the house like in the table are:
1
2
3
5
IDS (without 4 because it's deleted) insert the house as ID 4.
I tried to count the lines (cache_num_rows()), but if I count them now it will make the new house with ID 5 in this case and there will be 2 houses with ID 5

I hope you understand me, sorry for my bad English!
Reply


Messages In This Thread
MySQL ID - by Kraeror - 19.01.2019, 11:06
Re: MySQL ID - by Chyakka - 19.01.2019, 12:59
Re: MySQL ID - by Hunud - 19.01.2019, 13:11

Forum Jump:


Users browsing this thread: 1 Guest(s)