For years I've been using SELECT @@IDENTITY AS ID in my code to get the record 
ID for a newly inserted record. And now I'm wondering... would this, or 
something similar, work inside an insert statement?

I'm working on some insert code right now and one of the fields is a notes 
field that I'm storing some HTML, including (possibly) a path to an image that 
would be based on the record ID, ie; /path/to/###/record/image.jpg

I know it's a bit redundant, and that I could make an image field in the table 
and automate the appearance of the image through code, but I was wondering if 
there was anything in the SQL insert statement that would be aware of the 
impending unique ID that I could use.

Mik




--------
Michael Muller
Admin, MontagueMA.net Website
work (413) 863-0030
cell (413) 320-5336
skype: michaelBmuller
http://www.MontagueMA.net

Eschew Obfuscation




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Upgrade to Adobe ColdFusion MX7
The most significant release in over 10 years. Upgrade & see new features.
http://www.adobe.com/products/coldfusion?sdid=RVJR

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:273013
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to