freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: "Lowden, James K" <LowdenJK AT bernstein.com>
- To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] SELECT @@IDENTITY AS InsertID
- Date: Wed, 16 Nov 2005 09:47:03 -0500
> From: Shaun Craig
> Sent: Wednesday, November 16, 2005 6:01 AM
>
> At present i've taken out my select @@identity and replaced it with
> a select top 1 ... order by ...desc, this also gets me my identity,
> its safe for each 'Event' as another 'Event' from the same device
> cant be processed till this 'Event' would be finished.
>
> I dont use any stored procedures as code will have to be converted
> to connect to mysql eventually.
Your code will be standards-conformant and faster if you use 'select
max(ID)' instead of "top 1 ... order by". It's much less work for the
server, especially if (as should be the case) the ID is the first
element of a unique index.
--jkl
-----------------------------------------
The information contained in this transmission may be privileged and
confidential and is intended only for the use of the person(s) named
above. If you are not the intended recipient, or an employee or agent
responsible
for delivering this message to the intended recipient, any review,
dissemination,
distribution or duplication of this communication is strictly prohibited. If
you are
not the intended recipient, please contact the sender immediately by reply
and destroy all copies of the original message. Please note that we do not
accept
account orders and/or instructions by e-mail, and therefore will not be
responsible
for carrying out such orders and/or instructions. If you, as the intended
recipient
of this message, the purpose of which is to inform and update our clients,
prospects
and consultants of developments relating to our services and products, would
not
like to receive further e-mail correspondence from the sender, please "reply"
to the
sender indicating your wishes. In the U.S.: 1345 Avenue of the Americas, New
York,
NY 10105.
-
Re: [freetds] SELECT @@IDENTITY AS InsertID
, (continued)
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Pickett, David, 11/10/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Rogers, Tom, 11/10/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Pickett, David, 11/10/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Shaun Craig, 11/14/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Shaun Craig, 11/15/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Shaun Craig, 11/14/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Shaun Craig, 11/15/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Igor Korot, 11/15/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Shaun Craig, 11/16/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
martin, 11/16/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Shaun Craig, 11/16/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
martin, 11/16/2005
-
Re: [freetds] SELECT @@IDENTITY AS InsertID,
Shaun Craig, 11/16/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Lowden, James K, 11/16/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, ZIGLIO, Frediano, VF-IT, 11/16/2005
- Re: [freetds] SELECT @@IDENTITY AS InsertID, Pickett, David, 11/16/2005
Archive powered by MHonArc 2.6.24.