CyrusAyers
Programmer
Hi, Im using Access with an ASP interface. The primary key for my records is an autonumber field (im calling it ID). I'm having problems re-displaying the contents of a form when its purpose is to insert a new record -- it dosent know what ID to use in the SELECT statement. Heres the code im using currently. Any ideas would be very appriciated!
post_date = now()
Title = Trim(fixQuotes(request("Title")))
Category = Trim(fixQuotes(request("CatSelect")))
Content = Trim(fixQuotes(request("Content")))
sqlString = "insert into foodguru (post_date, title, category, content) VALUES ('" & post_date & "', '" & Title & "', '" & Category & "', '" & Content & "')"
conn.Execute (sqlString)
PS I know that SQL uses @@IDENTITY for this purpose...
Thanks,
Cyrus
post_date = now()
Title = Trim(fixQuotes(request("Title")))
Category = Trim(fixQuotes(request("CatSelect")))
Content = Trim(fixQuotes(request("Content")))
sqlString = "insert into foodguru (post_date, title, category, content) VALUES ('" & post_date & "', '" & Title & "', '" & Category & "', '" & Content & "')"
conn.Execute (sqlString)
PS I know that SQL uses @@IDENTITY for this purpose...
Thanks,
Cyrus