I want to get a field from the last tuple I have inserted to a table using SQL Server 2008 R2?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Basically, what you need to do is:
You need to define how to order the data so that you get the “latest” . If you sort by string, int or datetime, you’ll probably want to sort in a descending order to get the most recent first.
Since you didn’t provide any table structure or field names at all, this is the best we can do….. next time: please ask a bit more focused – provide more details! We’re good programmer – but not mind readers. We don’t know your system or your database or your setup – you need to tell us.