473,379 Members | 1,167 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

insert into error

I have the following code in vb.net aplication. It is simply trying to save user info into a table :

strSQL = "insert into Users (UserName,Password,SecurityLevel,Active) Values ('jasontest','serewrwf',2,Yes)"
rs = cn.Execute(strSQL)

I get an error saying that I have a syntax error when I run it from vb.net application, but it works fine if I run it in access???

Any suggestions?

Thanks
Jul 24 '07 #1
2 1110
puppydogbuddy
1,923 Expert 1GB
I have the following code in vb.net aplication. It is simply trying to save user info into a table :

strSQL = "insert into Users (UserName,Password,SecurityLevel,Active) Values ('jasontest','serewrwf',2,Yes)"
rs = cn.Execute(strSQL)

I get an error saying that I have a syntax error when I run it from vb.net application, but it works fine if I run it in access???

Any suggestions?

Thanks
The VB.NET application user/administrator probably needs to have the FULL rights to the shared folder which the access database located in order to do inserts, updates, and deletes.
Jul 24 '07 #2
It turned out to be the password field. I changed the name to UserPassword and it worked. Still don't know why it woeks in access, but not when sent as a SQL string from vb.net.
Jul 25 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Murali Kanaga | last post by:
Greetings! When I run the following SQL statement in Perl, I get an error stating: any help/pointers how this can be resolved? Thanks, -Murali SQL note_insert error: "There are more...
1
by: INSERT ERROR | last post by:
I am trying to INSERT record in MYSQL database, but each time the code tries to execute the command: MySQL_cmdGLAccount.ExecuteNonQuery(), it reports an error with the message "COLUMN COUNT...
3
by: INSERT ERROR | last post by:
I am trying to INSERT record in MYSQL database, but each time the code tries to execute the command: MySQL_cmdGLAccount.ExecuteNonQuery(), it reports an error with the message "COLUMN COUNT...
8
by: erin.sebastian | last post by:
Hi all, I have a really silly problem that i can't find the answer too. I am working with VB.NET and i am trying to insert a new record into my access database (pretty easy right?) well i am...
3
by: phil2phil | last post by:
Hi, I'm working on an asp where I wanted to do a simple insert using data from another table, structure is: Table A has columns - ID, Code, Type Table B has columns - key, FName, LNAme, DOB, cd,...
3
by: siamesedream | last post by:
Hello, I'm having trouble using the insert method of an ObjectDataSource that uses a custom DataObjectType. If I'm using a custom DataObjectType does my insert method have to take that object,...
2
by: technocraze | last post by:
Hi guys, I have encountered this error when updating the values to the MS Acess table. Error : Update on linked table failed. ODBC sql server error Timeout expired. MS Acess is my front end and...
0
by: Peter Nofelt | last post by:
Hi all, ISSUE: ==================== In SQL 2005 (sp2) I get the following error when preforming a bulk insert with an associated xml format file: "Could not bulk insert. Unknown version of...
3
by: Greg Corradini | last post by:
Hello, I'm trying to perform a simple insert statement into a table called Parcel_Test (see code below). Yet, I get an error message that I've never seen before (see traceback below). I've tried...
2
by: Greg Corradini | last post by:
Hello, I've never gotten this traceback error before using mx.ODBC. Any ideas about resolving this issue? The statement and the error it generates are listed below. curse.execute("Insert into...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.