SQL Server and Access

I was looking in the MSDN forums for a site for access questions. I need to modify some sql server code to work for access. I get a "missing operator" exception when I try to execute this sql server code in my new application.

I get very confused about what in a access sql command required brackets/quotes.

Where can I go in the forums to get questions addressed regarding access?

Dim UpdateCommandAsString

UpdateCommand = "UPDATE " & AdditionStructure.DatabaseTable & " SET ChildIndexList = @ChildIndexList FROM " & AdditionStructure.DatabaseTable & " WHERE (ID = @ID)"

Dim MyUpdateCommandAsNew OleDbCommand(UpdateCommand, Con)

MyUpdateCommand.Parameters.Add("@ID", AdditionStructure.ParentId)

MyUpdateCommand.Parameters.Add("@ChildIndexList", AdditionStructure.ParentChildIndexList)

MyUpdateCommand.ExecuteNonQuery()

[1250 byte] By [FredHerring] at [2008-2-7]
# 1

Hi,

I'm moving this post to .NET Framework Data Access and Storage.

Ok, you place brackets on fields that has a corresponding keyword in access or sql server. Also fields witeh spaces are required to have a bracket. Quotes are mainly required o string, datetime types...

cheers,

Paul June A. Domag

PaulDomag at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...
# 2

Thanks, Paul.

Here's the link to the post in the Data Access and Storage forum:

http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=67915

David Sceppa

ADO.NET Program Manager

Microsoft

DavidSceppa at 2007-9-9 > top of Msdn Tech,SQL Server,SQL Server Data Access...

SQL Server

Site Classified