Bug #9972 | Client | ||
---|---|---|---|
Submitted: | 18 Apr 2005 14:16 | Modified: | 19 May 2005 7:56 |
Reporter: | Popescu Cosmin | Email Updates: | |
Status: | No Feedback | Impact on me: | |
Category: | Connector / ODBC Documentation | Severity: | S2 (Serious) |
Version: | 5.0.3 beta | OS: | Windows (Windows) |
Assigned to: | CPU Architecture: | Any |
[18 Apr 2005 14:16]
Popescu Cosmin
[18 Apr 2005 16:01]
MySQL Verification Team
I wasn't able to repeat using ADO with Access 2003 and 3.51.11-1. Could you please provide a code test case like you are using ? Thanks in advance.
[19 Apr 2005 7:56]
Popescu Cosmin
The exact query is select (sum(intrare-iesire)) as mstoc from nir where cod_p=911 I use VB .NET. I didn't try this from Access. The connection string is DRIVER={MySQL ODBC 3.51 Driver};database=dbname;server=server;uid=UserID;pwd=UserPassword; I pass this string to an ADODB.Connection: dim cnstr as string="DRIVER={MySQL ODBC 3.51 Driver};database=dbname;server=server;uid=UserID;pwd=UserPassword;" dim db as new adodb.connection db.connectionstring=cnstr Try db.Open() Catch err As System.Exception MsgBox(err.Message) Application.Exit() Exit Sub End Try dim rec as new adodb.recordset dim sql as string="select (sum(intrare-iesire)) as mstoc from nir where cod_p=911" rec.ActiveConnection = db rec.CursorLocation = ADODB.CursorLocationEnum.adUseClient rec.Open(sql, db, ADODB.CursorTypeEnum.adOpenStatic, ADODB.LockTypeEnum.adLockPessimistic) This is the code. After rec.open, I get the error Multiple-step operation generated errors. If i change rec.CursorLocation = ADODB.CursorLocationEnum.adUseClient to rec.CursorLocation = ADODB.CursorLocationEnum.adUseServer, then the query works, but the RecordCount property returns -1. Also, if I change the query to sql=select correction(sum(intrare-iesire)) as mstoc from nir where cod_p=911 it works, but then I have a huge program. I can't change all the queries that use sum function. I hope there is a workaround without having to change my code. Thank you for the reply.
[19 May 2005 23:00]
Bugs System
No feedback was provided for this bug for over a month, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open".