RSS Forums RSS
Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums

Problems with INSERT INTO and ADO

Join Date: Nov 2005
Location: Montreal, QC (Almost)
Posts: 130
Reputation: Yomet is an unknown quantity at this point 
Rep Power: 4
Solved Threads: 9
Yomet Yomet is offline Offline
Junior Poster

Re: Problems with INSERT INTO and ADO

  #6  
May 13th, 2007
Hi PVBert,

Thanks for the reply, however, I have some clarifications and a question about it.

Clarifications: The table inserted into is called tblUsers and has the following structure:
tblUsers
===================
UserID       AutoNumber
UserName     String  (Not NULL, not empty string)
Password     String  (Not NULL, Empty string OK, Default "")
Active       Boolean (Not NULL, default True)
Comment      String  (Not NULL, Empty String OK, Default "")
Question: Are you saying that I need to delimit the actual field names in single quotes? i.e. that the SQL statement sent to ADO should be INSERT INTO tblUsers ('UserName', 'Password') Values ('Hello', 'World')

I have never used single quotes for delimiting the actual names of objects in SQL but if you say that this will work I'll try it on Monday.

Thanks

Yomet
Reply With Quote  
All times are GMT -4. The time now is 2:06 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC