Here is the SQL statement that I'm trying to execute
INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel Generic',
'Rbl')


My database has a table name 'Tbl_NameCharacter'
it has 3 fields, the PK is an autonumber 'CharacterID'
the second is a 'text' field named 'Character'
and the third is also a 'text' field named 'Code'

I don't get it.

Here are the details from the OleDbException
System.Object {System.Data.OleDb.OleDbError} System.Object
Message "Syntax error in INSERT INTO statement." string
message "Syntax error in INSERT INTO statement." string
NativeError -529993134 int
nativeError -529993134 int
Source "Microsoft JET Database Engine" string
source "Microsoft JET Database Engine" string
SQLState "3000" string
sqlState "3000" string



Any ideas?

Re: ExecuteNonQuery() says I have bad SQL by William

William
Wed Sep 29 16:36:32 CDT 2004

Try this:
INSERT INTO Tbl_NameCharacter([Character], [Code]) VALUES('Rebel Generic',
'Rbl')

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________

"SteveK" <asasd@asdfasdfsd.com> wrote in message
news:%23Vd9PsmpEHA.3396@tk2msftngp13.phx.gbl...
> Here is the SQL statement that I'm trying to execute
> INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel Generic',
> 'Rbl')
>
>
> My database has a table name 'Tbl_NameCharacter'
> it has 3 fields, the PK is an autonumber 'CharacterID'
> the second is a 'text' field named 'Character'
> and the third is also a 'text' field named 'Code'
>
> I don't get it.
>
> Here are the details from the OleDbException
> System.Object {System.Data.OleDb.OleDbError} System.Object
> Message "Syntax error in INSERT INTO statement." string
> message "Syntax error in INSERT INTO statement." string
> NativeError -529993134 int
> nativeError -529993134 int
> Source "Microsoft JET Database Engine" string
> source "Microsoft JET Database Engine" string
> SQLState "3000" string
> sqlState "3000" string
>
>
>
> Any ideas?
>
>



Re: ExecuteNonQuery() says I have bad SQL by SteveK

SteveK
Wed Sep 29 17:01:52 CDT 2004

that was it, thank Bill.

I guess Character is a reserved word. Hmm. ;)



"William (Bill) Vaughn" <billvaRemoveThis@nwlink.com> wrote in message
news:%236pgkxmpEHA.2032@TK2MSFTNGP10.phx.gbl...
> Try this:
> INSERT INTO Tbl_NameCharacter([Character], [Code]) VALUES('Rebel Generic',
> 'Rbl')
>
> --
> ____________________________________
> William (Bill) Vaughn
> Author, Mentor, Consultant
> Microsoft MVP
> www.betav.com
> Please reply only to the newsgroup so that others can benefit.
> This posting is provided "AS IS" with no warranties, and confers no
rights.
> __________________________________
>
> "SteveK" <asasd@asdfasdfsd.com> wrote in message
> news:%23Vd9PsmpEHA.3396@tk2msftngp13.phx.gbl...
> > Here is the SQL statement that I'm trying to execute
> > INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel Generic',
> > 'Rbl')
> >
> >
> > My database has a table name 'Tbl_NameCharacter'
> > it has 3 fields, the PK is an autonumber 'CharacterID'
> > the second is a 'text' field named 'Character'
> > and the third is also a 'text' field named 'Code'
> >
> > I don't get it.
> >
> > Here are the details from the OleDbException
> > System.Object {System.Data.OleDb.OleDbError} System.Object
> > Message "Syntax error in INSERT INTO statement." string
> > message "Syntax error in INSERT INTO statement." string
> > NativeError -529993134 int
> > nativeError -529993134 int
> > Source "Microsoft JET Database Engine" string
> > source "Microsoft JET Database Engine" string
> > SQLState "3000" string
> > sqlState "3000" string
> >
> >
> >
> > Any ideas?
> >
> >
>
>



Re: ExecuteNonQuery() says I have bad SQL by William

William
Wed Sep 29 19:28:05 CDT 2004

Ah... yup.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________

"SteveK" <asasd@asdfasdfsd.com> wrote in message
news:uDsPu$mpEHA.2104@TK2MSFTNGP10.phx.gbl...
> that was it, thank Bill.
>
> I guess Character is a reserved word. Hmm. ;)
>
>
>
> "William (Bill) Vaughn" <billvaRemoveThis@nwlink.com> wrote in message
> news:%236pgkxmpEHA.2032@TK2MSFTNGP10.phx.gbl...
>> Try this:
>> INSERT INTO Tbl_NameCharacter([Character], [Code]) VALUES('Rebel
>> Generic',
>> 'Rbl')
>>
>> --
>> ____________________________________
>> William (Bill) Vaughn
>> Author, Mentor, Consultant
>> Microsoft MVP
>> www.betav.com
>> Please reply only to the newsgroup so that others can benefit.
>> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>> __________________________________
>>
>> "SteveK" <asasd@asdfasdfsd.com> wrote in message
>> news:%23Vd9PsmpEHA.3396@tk2msftngp13.phx.gbl...
>> > Here is the SQL statement that I'm trying to execute
>> > INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel Generic',
>> > 'Rbl')
>> >
>> >
>> > My database has a table name 'Tbl_NameCharacter'
>> > it has 3 fields, the PK is an autonumber 'CharacterID'
>> > the second is a 'text' field named 'Character'
>> > and the third is also a 'text' field named 'Code'
>> >
>> > I don't get it.
>> >
>> > Here are the details from the OleDbException
>> > System.Object {System.Data.OleDb.OleDbError} System.Object
>> > Message "Syntax error in INSERT INTO statement." string
>> > message "Syntax error in INSERT INTO statement." string
>> > NativeError -529993134 int
>> > nativeError -529993134 int
>> > Source "Microsoft JET Database Engine" string
>> > source "Microsoft JET Database Engine" string
>> > SQLState "3000" string
>> > sqlState "3000" string
>> >
>> >
>> >
>> > Any ideas?
>> >
>> >
>>
>>
>
>



Re: ExecuteNonQuery() says I have bad SQL by TomNowak

TomNowak
Fri Feb 25 09:19:04 CST 2005

I am having the same issue and my fields are date, child, activity,
starttime, and endtime? Are any of these reserved words?

"William (Bill) Vaughn" wrote:

> Ah... yup.
>
> --
> ____________________________________
> William (Bill) Vaughn
> Author, Mentor, Consultant
> Microsoft MVP
> www.betav.com
> Please reply only to the newsgroup so that others can benefit.
> This posting is provided "AS IS" with no warranties, and confers no rights.
> __________________________________
>
> "SteveK" <asasd@asdfasdfsd.com> wrote in message
> news:uDsPu$mpEHA.2104@TK2MSFTNGP10.phx.gbl...
> > that was it, thank Bill.
> >
> > I guess Character is a reserved word. Hmm. ;)
> >
> >
> >
> > "William (Bill) Vaughn" <billvaRemoveThis@nwlink.com> wrote in message
> > news:%236pgkxmpEHA.2032@TK2MSFTNGP10.phx.gbl...
> >> Try this:
> >> INSERT INTO Tbl_NameCharacter([Character], [Code]) VALUES('Rebel
> >> Generic',
> >> 'Rbl')
> >>
> >> --
> >> ____________________________________
> >> William (Bill) Vaughn
> >> Author, Mentor, Consultant
> >> Microsoft MVP
> >> www.betav.com
> >> Please reply only to the newsgroup so that others can benefit.
> >> This posting is provided "AS IS" with no warranties, and confers no
> > rights.
> >> __________________________________
> >>
> >> "SteveK" <asasd@asdfasdfsd.com> wrote in message
> >> news:%23Vd9PsmpEHA.3396@tk2msftngp13.phx.gbl...
> >> > Here is the SQL statement that I'm trying to execute
> >> > INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel Generic',
> >> > 'Rbl')
> >> >
> >> >
> >> > My database has a table name 'Tbl_NameCharacter'
> >> > it has 3 fields, the PK is an autonumber 'CharacterID'
> >> > the second is a 'text' field named 'Character'
> >> > and the third is also a 'text' field named 'Code'
> >> >
> >> > I don't get it.
> >> >
> >> > Here are the details from the OleDbException
> >> > System.Object {System.Data.OleDb.OleDbError} System.Object
> >> > Message "Syntax error in INSERT INTO statement." string
> >> > message "Syntax error in INSERT INTO statement." string
> >> > NativeError -529993134 int
> >> > nativeError -529993134 int
> >> > Source "Microsoft JET Database Engine" string
> >> > source "Microsoft JET Database Engine" string
> >> > SQLState "3000" string
> >> > sqlState "3000" string
> >> >
> >> >
> >> >
> >> > Any ideas?
> >> >
> >> >
> >>
> >>
> >
> >
>
>
>

Re: ExecuteNonQuery() says I have bad SQL by Jim

Jim
Fri Feb 25 09:37:12 CST 2005

List of Microsoft Jet 4.0 reserved words

http://support.microsoft.com/default.aspx?scid=kb;EN-US;321266

This list includes Date

"Tom Nowak" <TomNowak@discussions.microsoft.com> wrote in message
news:0CAFE70D-C902-4522-A6C0-E93DF7047E7E@microsoft.com...
>I am having the same issue and my fields are date, child, activity,
> starttime, and endtime? Are any of these reserved words?
>
> "William (Bill) Vaughn" wrote:
>
>> Ah... yup.
>>
>> --
>> ____________________________________
>> William (Bill) Vaughn
>> Author, Mentor, Consultant
>> Microsoft MVP
>> www.betav.com
>> Please reply only to the newsgroup so that others can benefit.
>> This posting is provided "AS IS" with no warranties, and confers no
>> rights.
>> __________________________________
>>
>> "SteveK" <asasd@asdfasdfsd.com> wrote in message
>> news:uDsPu$mpEHA.2104@TK2MSFTNGP10.phx.gbl...
>> > that was it, thank Bill.
>> >
>> > I guess Character is a reserved word. Hmm. ;)
>> >
>> >
>> >
>> > "William (Bill) Vaughn" <billvaRemoveThis@nwlink.com> wrote in message
>> > news:%236pgkxmpEHA.2032@TK2MSFTNGP10.phx.gbl...
>> >> Try this:
>> >> INSERT INTO Tbl_NameCharacter([Character], [Code]) VALUES('Rebel
>> >> Generic',
>> >> 'Rbl')
>> >>
>> >> --
>> >> ____________________________________
>> >> William (Bill) Vaughn
>> >> Author, Mentor, Consultant
>> >> Microsoft MVP
>> >> www.betav.com
>> >> Please reply only to the newsgroup so that others can benefit.
>> >> This posting is provided "AS IS" with no warranties, and confers no
>> > rights.
>> >> __________________________________
>> >>
>> >> "SteveK" <asasd@asdfasdfsd.com> wrote in message
>> >> news:%23Vd9PsmpEHA.3396@tk2msftngp13.phx.gbl...
>> >> > Here is the SQL statement that I'm trying to execute
>> >> > INSERT INTO Tbl_NameCharacter(Character, Code) VALUES('Rebel
>> >> > Generic',
>> >> > 'Rbl')
>> >> >
>> >> >
>> >> > My database has a table name 'Tbl_NameCharacter'
>> >> > it has 3 fields, the PK is an autonumber 'CharacterID'
>> >> > the second is a 'text' field named 'Character'
>> >> > and the third is also a 'text' field named 'Code'
>> >> >
>> >> > I don't get it.
>> >> >
>> >> > Here are the details from the OleDbException
>> >> > System.Object {System.Data.OleDb.OleDbError} System.Object
>> >> > Message "Syntax error in INSERT INTO statement." string
>> >> > message "Syntax error in INSERT INTO statement." string
>> >> > NativeError -529993134 int
>> >> > nativeError -529993134 int
>> >> > Source "Microsoft JET Database Engine" string
>> >> > source "Microsoft JET Database Engine" string
>> >> > SQLState "3000" string
>> >> > sqlState "3000" string
>> >> >
>> >> >
>> >> >
>> >> > Any ideas?
>> >> >
>> >> >
>> >>
>> >>
>> >
>> >
>>
>>
>>