Thread: Chapter 15!!
View Single Post
  #10 (permalink)  
Old March 10th, 2004, 08:04 AM
Imar's Avatar
Imar Imar is offline
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts

It seems that the insert works fine now, doesn't it?

Using a Form in Access may not give you the same results as putting in the SQL statement directly in the Query Designer. For example, you could be forgetting quotes around a field's value which can result in an error. This may not be a problem in the Access database. So, effectively you are comparing apples with pears. Even if your Access form works, you're not really checking whether the INSERT statement from the ASP page works.

Also, there are subtle differences in the way data and columns are handled. For example, Password is a reserved keyword. Access will let you create a column by that name, and even let you insert data in that column. However, when you use ADO with a column named password, you run into problems.

Do you get this error when the insert completes? If you have a new user, you execute the INSERT statement. The recordset rsUsers will be empty in that case. However, the error message you get seems to indicate that you are updating the recordset, but your code doesn't show any updates anymore. Is this all the code? How about you remove all the commented and other irrelevant stuff, bringing the page back to the bare minimum.


Imar Spaanjaars
Everyone is unique, except for me.