Tutorials
Resources
Forum
Interview
Jobs
Projects
Offshore Development
Mentor
|
Code Converter
|
Articles
|
Code Factory
|
Computer Jokes
|
Members
|
Peer Appraisal
|
IT Companies
|
Bookmarks
|
Revenue Sharing
|
Talk to Us
|
My Profile
Sign In
Register
AdSense Revenue
Gifts
Active Members
Today
D.Jeya kumar(J...
(334)
ANIL PANDEY
(331)
UltimateRengan
(188)
Last 7 Days
Athira Appukut...
(1492)
D.Jeya kumar(J...
(1474)
UltimateRengan
(1399)
more...
how to select last inserted record in sqlserver2005
Posted Date: 23 Jul 2008 Resource Type:
Code Snippets
Category:
SQL
Posted By:
Aradhana Kumari
Member Level:
Gold
Rating:
Points
: 2
//how to select last inserted record from a table in sqlserver 2005
create stroreprocedure selectlastrecord
@sd varchar(50),
@as varchar(50)
AS
BEGIN
insert into add1(name,roll) values(@sd,@as)
SELECT IDENT_CURRENT('add1');
//SELECT @@IDENTITY
END
GO
--exec hggh 'kkl','jhjh'
Output wil give the last inserted record
Responses
Author:
Nirupa Rani Acharya
27 Jul 2008
Member Level:
Bronze
Points
: 0
Thanks 4 dis code. plez share ur knowledge with us...
Feedbacks
Popular Tags
What are tags ?
Search Tags
Sign In
Work in Microsoft
.
Post Feedback
This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must
Sign In
to post a response.
Next Resource:
Rounding numbers in MS SQL
Previous Resource:
SQL Query to Find the Nth highest Colum Value in a Table.
Return to Discussion Resource Index
Post New Resource
Category:
SQL
Post resources and
earn money
!
Related Resources
How to get the name of the local server in SQL.
How to get the number of qualifying rows currently in the last cursor opened on the connection
Select all Columns At Once
How to use stored procedure to take large Text input and populate in a table
How to format date in MS SQL
dotNet Slackers
BizTalk Adaptors
Web Design
audio conferencing services
Contact Us
Privacy Policy
Terms Of Use