P
Paul Richardson
I have split a database following the directions found in another thread here
(the back end only has the tables, the rest is in the front end, including
queries). In my VB code, I instantiate a command object and set CommandText
property to the name of a query, the CommandType property to adCmdStoredProc,
and the ActiveConnection property to an ADODB.Connection object. In
addition, I create parameter objects (using the names as shown in the SQL
View of the Query) and add them to the Parameters collection. I set the
parameters and attempt to load a recordset object with the command's Execute
method. This fails with an error that says something about a "Multi-Step
OLEDB operation generated errors" if I have defined the Connection String
with a "Provider=Microsoft.Jet.OLEDB.4.0;etc." and with an error that says
"[Microsoft][ODBC Microsoft Access Driver]Optional feature not implemented."
if the ConnectionString is defined "DSN=SilentWar" (with SilentWar set
through the ODBC Administration). I have found a KB article referring to the
first error that had a registry mod. That is not the problem here.
If I take the text of the same query and create a string variable (with the
parameter values inserted where appropriate), set the CommandText property to
the string, and the CommandType property to adCmdText, I can load the
recordset object with no problem using the Execute method. Note that I don't
instantiate/add parameter objects in this situation and I am using the same
Connection object.
What have I missed? or what am I doing wrong? Do the queries need to
reside on the Back End, as well as the tables?
TIA,
Paul
(the back end only has the tables, the rest is in the front end, including
queries). In my VB code, I instantiate a command object and set CommandText
property to the name of a query, the CommandType property to adCmdStoredProc,
and the ActiveConnection property to an ADODB.Connection object. In
addition, I create parameter objects (using the names as shown in the SQL
View of the Query) and add them to the Parameters collection. I set the
parameters and attempt to load a recordset object with the command's Execute
method. This fails with an error that says something about a "Multi-Step
OLEDB operation generated errors" if I have defined the Connection String
with a "Provider=Microsoft.Jet.OLEDB.4.0;etc." and with an error that says
"[Microsoft][ODBC Microsoft Access Driver]Optional feature not implemented."
if the ConnectionString is defined "DSN=SilentWar" (with SilentWar set
through the ODBC Administration). I have found a KB article referring to the
first error that had a registry mod. That is not the problem here.
If I take the text of the same query and create a string variable (with the
parameter values inserted where appropriate), set the CommandText property to
the string, and the CommandType property to adCmdText, I can load the
recordset object with no problem using the Execute method. Note that I don't
instantiate/add parameter objects in this situation and I am using the same
Connection object.
What have I missed? or what am I doing wrong? Do the queries need to
reside on the Back End, as well as the tables?
TIA,
Paul