I am opening a recordset using an SQL statement. The code is below. I am getting the error message: "Method 'Open' of object '_recordset' has failed." For some reason, the query is failing on one field. If I remove this field from the query, it works. If I susbstitute another field for this field, it works.
Why would an SQL query fail on one field? It is a normal text field with nothing different from other fields that I can determine.
Any help would be GREATLY appreciated.
Betsyr
Set rst = New Recordset
rst.ActiveConnection = CurrentProject.Connection
rst.CursorType = adOpenStatic
rst.LockType = adLockReadOnly
rst.Open Source:="SELECT [New Pieces Table].Title, [New Pieces Table].Medium, [New Pieces Table].Edition, [New Pieces Table].ArtistID, [New Pieces Table].Size FROM [New Pieces Table];", Options:=adCmdText
I am using Access 2002!
Why would an SQL query fail on one field? It is a normal text field with nothing different from other fields that I can determine.
Any help would be GREATLY appreciated.
Betsyr
Set rst = New Recordset
rst.ActiveConnection = CurrentProject.Connection
rst.CursorType = adOpenStatic
rst.LockType = adLockReadOnly
rst.Open Source:="SELECT [New Pieces Table].Title, [New Pieces Table].Medium, [New Pieces Table].Edition, [New Pieces Table].ArtistID, [New Pieces Table].Size FROM [New Pieces Table];", Options:=adCmdText
I am using Access 2002!