Hello, dear SAP DB gurus!
I am still trying to work with new SQLDBC interface, and still have some
problems.
The latest one is the following:
I have a table, T2, with column C5 of type FIXED(10,2). Now I am trying to
update it using prepared
statement with parameters, like this:
// ...
SQLDBC_PreparedStatement *stmt = conn->createPreparedStatement();
rc = stmt->prepare("update t2 set c5 = ? where c5 = ?");
if(SQLDBC_OK != rc) {
fprintf(stderr, "Prepare failed %s\n", stmt->error().getErrorText());
return (1);
}
int indicator = 10;
rc = stmt->bindParameter(1, SQLDBC_HOSTTYPE_ASCII, "99.98", &indicator,
10);
if(SQLDBC_OK != rc) {
fprintf(stderr, "bind 1 failed %s\n", stmt->error().getErrorText());
return (1);
}
rc = stmt->bindParameter(2, SQLDBC_HOSTTYPE_ASCII, "99.97", &indicator,
10);
if(SQLDBC_OK != rc) {
fprintf(stderr, "bind 2 failed %s\n", stmt->error().getErrorText());
return (1);
}
rc = stmt->execute();
if(SQLDBC_OK != rc) {
fprintf(stderr, "Execution failed %s\n", stmt->error().getErrorText());
return (1);
}
// ...
Everything goes OK, but the last statement gives me SQLDBC_NOT_OK with error
text "Conversion not supported".
Strange for me, because back conversion (getting FIXED columns as
SQLDBC_HOSTTYPE_ASCII) works great.
As far as I know, SQLDBC_HOSTTYPE_ODBCNUMERIC type is not supported at all
yet.
So, my questions are:
- Are there any bugs or misunderstanding in my code?
- How to pass values for FIXED columns via parameters in SQLDBC (without
loosing precision, I mean)?
- When all thge mentioned functionality will be supported?
Thank you for any suggestions,
Valeriy
--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]