i have a MySQL table with the following columns: employeeID, firstName, lastName, gender, salary. whenever i insert a new record for this table i want to be able to retrieve the employeeID of that record. how should i write the commands in VB.Net
dinhunzvi
0
Newbie Poster
Recommended Answers
Jump to PostI do not know much about MySQL but if you have the aggregate function MAX() you can use it to retrieve the last inserted record in a table as
SELECT MAX(employeeID) FROM Table
or you can you use a subquery as
SELECT firstName, …
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.