Re: Can this be done??
From: CT (carstent_at_spammersgoawaydotnetservices.biz)
Date: 04/28/04
- Next message: Cor Ligthert: "Re: Introduction to OLAP Questions..."
- Previous message: CT: "Re: Working with a remote server"
- Maybe in reply to: Morten Overgaard: "Can this be done??"
- Next in thread: Morten Overgaard: "Re: Can this be done??"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 28 Apr 2004 10:21:08 +0200
Not quite, as the updated rows haven't been commited yet.
-- Carsten Thomsen Enterprise Development with VS .NET, UML, and MSF http://www.apress.com/book/bookDisplay.html?bID=105 "Akhil Bansal" <akhil_bansal20@hotmail.com> wrote in message news:Ok3qHSNLEHA.1612@TK2MSFTNGP12.phx.gbl... > Hi Kevin / Morten > I think it is possible. > What you have to do is Just Create a insert Trigger on the table in > which you are inserting the record and in the Trigger just write the > statement > Select * from Inserted > > as Inserted table contains the newly inserted rows and fires one time of a > insert. > I thing this should work. > > > regds..... > Akhil > > > > > "Kevin Yu [MSFT]" <v-kevy@online.microsoft.com> wrote in message > news:TtTwbpMLEHA.2520@cpmsftngxa10.phx.gbl... >> Thanks for Bill's quick response! >> >> Hi Morten, >> >> First of all, I would like to confirm my understanding of your issue. >> From >> your description, I understand that you need to create a SELECT command >> that will only return the records inserted within the transaction which >> hasn't been committed. If there is any misunderstanding, please feel free >> to let me know. >> >> As far as I know, this is impossible to be achieved in transaction. > Because >> the SQL server database engine commits and rolls back transactions by >> checking the transaction log. However, the transaction log cannot be >> accessed by SELECT statement. >> >> For workaround, I think you can insert the new records into a DataSet and >> use DataSet.GetChanges to get the newly inserted rows. For more > information >> about DataSet.GetChanges method, please check the following link: >> >> > http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/ >> frlrfSystemDataDataSetClassGetChangesTopic.asp >> >> HTH. If anything is unclear, please feel free to reply to the post. >> >> Kevin Yu >> ======= >> "This posting is provided "AS IS" with no warranties, and confers no >> rights." >> > >
- Next message: Cor Ligthert: "Re: Introduction to OLAP Questions..."
- Previous message: CT: "Re: Working with a remote server"
- Maybe in reply to: Morten Overgaard: "Can this be done??"
- Next in thread: Morten Overgaard: "Re: Can this be done??"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|