Barry -

It's done through the JDBC driver, so it's probably right down into the DB core.

Mark

On Nov 12, 2007 4:35 PM, Barry Beattie <[EMAIL PROTECTED]> wrote:
>
> @Mark: is that SCOPE_IDENTITY or @@IDENTITY that the id is gotten from?
>
> @Scott: what happens if you change "new_id" to some other alias? (or
> additionally put new_id in square brackets)
>
> select scope_identity() as [new_id]
>
>
>
> On Nov 12, 2007 3:31 PM, Mark Mandel <[EMAIL PROTECTED]> wrote:
> >
> > If you dump out the insert query, you will see that the newly created
> > ID is there waiting for you, if you want to change your code around ;)
> >
> > Mark
> >
> > On Nov 12, 2007 2:41 PM, Scott Thornton
> > <[EMAIL PROTECTED]> wrote:
> > >
> > > Hi,
> > >
> > > Running version 8,0,0,176276 on local against a MS SQL 2005 database.
> > >
> > > I ran into a problem late last week where a query returning the id after 
> > > an insert eg:
> > >
> > > <cfquery ......>
> > > insert ........
> > > select scope_identity() as new_id
> > > </cfquery>
> > >
> > > the compiler would return the error queryname.new_id is undefined.
> > >
> > > The exact same code worked when executed against a cfmx6.1 against the 
> > > same database with nothing changed.
> > >
> > > The application has this usage throughout it and those other bits of code 
> > > are fine.
> > >
> > > Soo,
> > >
> > > I was wondering has anyone ran into this intermittent problem before?
> > >
> > > I notice there is a Hot Fix available 
> > > http://kb.adobe.com/selfservice/viewContent.do?externalId=kb402466&sliceId=1
> > >  for CF 8...... but the issues list does not seem to reference any 
> > > database issues...
> > >
> > > Is there a JDBC driver update available for it as well that I cannot find?
> > >
> > > Also, how do I find out what version of jdbc I have?
> > >
> > > Cheers,
> > >
> > >
> > > >
> > >
> >
> >
> >
> > --
> > E: [EMAIL PROTECTED]
> > W: www.compoundtheory.com
> >
> >
> > >
> >
>
>
> >
>



-- 
E: [EMAIL PROTECTED]
W: www.compoundtheory.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to