VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000
From: rmsterling (rmsterling_at_avaya.com)
Date: 10/21/04
- Next message: Roy: "How to repair MDAC in XP SP2?"
- Previous message: Brendan Reynolds: "Re: Can anybody show me how to open up a DAO connection to an Acce"
- Next in thread: William \(Bill\) Vaughn: "Re: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: William \(Bill\) Vaughn: "Re: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: rmsterling: "RE: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: rmsterling: "RE: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 21 Oct 2004 07:39:04 -0700
Problem running SELECT SQL query....
Using....
Visual Basic 6.0 SP5
ADO COM Object
Using ODBC
MDAC 2.8 Installed
Connecting to a Informix 7.3 Database located on a Unix Server.
Connection statement below connects the database with no problems.....
sConnectStr = "DSN=testname;UID=testuser;PWD=testpwd"
With gadoConnection_Test
.CursorLocation = adUseServer
.Provider = "MSDASQL"
.ConnectionString = sConnectStr
.CommandTimeout = 300
.Open
End With
When I go to execute a query .....
gsSQL = "SELECT testdata FROM testtable WHERE testdata='TEST' ORDER BY
testdata2;"
adoRS_Test.Open gsSQL, gadoConnection_Test, adOpenDynamic, adLockReadOnly
If Not adoRS_Test.BOF Then
Above query produces this error....
Error : -2147217900.
Native Error : 0.
SQL State : 37000.
Source : Microsoft OLE DB Provider for ODBC Drivers.
Description : [OpenLink][ODBC][Driver]Syntax error or access violation.
Tried running query through the ODBC layer in Access 2003 and the Query
executes fine.
I think the problem lies in the statement below which tells VB what ODBC
driver to use....
.Provider = "MSDASQL"
ODBC Driver details are below....
OpenLink Generic ODBC Driver
5.10.00.00
OpenLink Software
OLOD5032.DLL
18Sep2003
Could you tell me what I place in the .Provider property to make my
application work?
-- ---------------------------- Regards, Richard Sterling Senior Software Engineer Tel : +44 (0)1707 392200 ext 4815 Avaya ECS Ltd, United Kingdom mailto:rmsterling@avaya.com
- Next message: Roy: "How to repair MDAC in XP SP2?"
- Previous message: Brendan Reynolds: "Re: Can anybody show me how to open up a DAO connection to an Acce"
- Next in thread: William \(Bill\) Vaughn: "Re: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: William \(Bill\) Vaughn: "Re: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: rmsterling: "RE: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Reply: rmsterling: "RE: VB6-ADO-COM-ODBC-INFORMIX : Problem running query. SQL State 37000"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|