Do not use on any
shared computer
September 5, 2008 08:32pm pdt
 
[x]
Attachment Details

MS ACCESS QUERY

I am using MS ACCESS as database and C# windows application..
While i am trying to insert a name with single quote(') access throws error.
Let me know about the syntax.

Thanks in advance
1:
2:
3:
string query="insert into table1(CODE,NAME,LOCATION,JOBNO) values ('" + strCode+"','"+strPrjName+"','"+strLocation+"','"+strJobNo+"')";
 
i have (') in strPrjName and strLocation
Start your free trial to view this solution
Question Stats
Zone: Microsoft
Question Asked By: lword
Question Asked On: 07.18.2008
Participating Experts: 3
Points: 500
Views: 0
Translate:
Loading Advertisement...
 
[+][-]Expert Comment by MuhammadKashif
Expert Comment by MuhammadKashif:

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
[+][-]Expert Comment by emoreau

Rank: Genius

Expert Comment by emoreau:

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
[+][-]Expert Comment by boag2000

Rank: Sage

Expert Comment by boag2000:

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
[+][-]Expert Comment by emoreau

Rank: Genius

Expert Comment by emoreau:

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
[+][-]Expert Comment by boag2000

Rank: Sage

Expert Comment by boag2000:

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
Loading Advertisement...
20080723-EE-VQP-34 / EE_QW_2_20070628