You could try adding the data with a <CFQUERY ....>INSER.... and then
immediately after do a

        <CFQUERY....>
        SELECT ID
        FROM My_Table
        WHERE blah = whatwasjustadded
        AND blah2 = whatwasalsoadded
        </CFQUERY>

including as much info as possible so that you only get one record returned
and then output the ID as you would normally

HTH

-----Original Message-----
From: W Luke [mailto:[EMAIL PROTECTED]]
Sent: Friday, September 29, 2000 13:00
To: CF-Talk
Subject: AutoNumbers and INSERTS


Hi,

I'm inserting a load of data into a Table of an Access Database.  The ID
field is generated by AutoNumber.

As soon as the record has been inserted, I need to output what that ID was.
How can I do this?

Cheers

Will...

----------------------------------------------------------------------------
--
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.

------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to