MYSQL > Autoincrement-Problem
#1

How can i get the next ID that will be created in my Database for a autoincrement field?
Example:

id | name
1 | a
2 | b
3 | c

I delete 2 + 3
next ID would be 4

how do i get the ID 4 to use it in a string:
printf("The next ID is: 4, want to insert?",nextID);

Mysql from BlueG
Reply


Messages In This Thread
MYSQL > Autoincrement-Problem - by Meisternuke - 14.06.2015, 02:14
Re: MYSQL > Autoincrement-Problem - by [KHK]Khalid - 14.06.2015, 02:18
Re: MYSQL > Autoincrement-Problem - by Meisternuke - 14.06.2015, 02:19
Re: MYSQL > Autoincrement-Problem - by [KHK]Khalid - 14.06.2015, 02:21
Re: MYSQL > Autoincrement-Problem - by Emmet_ - 14.06.2015, 02:26
Re: MYSQL > Autoincrement-Problem - by Meisternuke - 14.06.2015, 02:41
Re: MYSQL > Autoincrement-Problem - by Emmet_ - 14.06.2015, 04:43
Re: MYSQL > Autoincrement-Problem - by Konstantinos - 14.06.2015, 10:30

Forum Jump:


Users browsing this thread: 3 Guest(s)