
If you were logged in you would be able to see more operations.
|
|
|
Environment:
|
Windows, MFC RFX functions
|
|
Microsoft MFC will perform RFX_BOOL by trying to bing a result column as a SQL_C_BIT. However the Firebird ODBC driver does create any conversions from some data type to SQL_C_BIT, resulting in a failed transfer. Not even converting to char(1) (which is documented as the bit data type alternative) works.
|
Description
|
Microsoft MFC will perform RFX_BOOL by trying to bing a result column as a SQL_C_BIT. However the Firebird ODBC driver does create any conversions from some data type to SQL_C_BIT, resulting in a failed transfer. Not even converting to char(1) (which is documented as the bit data type alternative) works. |
Show » |
|
Index: O:/devel/FirebirdODBC/OdbcConvert.cpp
===================================================================
--- O:/devel/FirebirdODBC/OdbcConvert.cpp (revision 50726)
+++ O:/devel/FirebirdODBC/OdbcConvert.cpp (revision 50727)
@@ -147,6 +147,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
bIdentity = true;
return &OdbcConvert::convTinyIntToTinyInt;
case SQL_C_SHORT:
@@ -191,6 +192,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
if ( from->scale || to->scale )
return &OdbcConvert::convShortToTinyIntWithScale;
return &OdbcConvert::convShortToTinyInt;
@@ -244,6 +246,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
if ( from->scale || to->scale )
return &OdbcConvert::convLongToTinyIntWithScale;
return &OdbcConvert::convLongToTinyInt;
@@ -291,6 +294,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
return &OdbcConvert::convFloatToTinyInt;
case SQL_C_SHORT:
case SQL_C_USHORT:
@@ -323,6 +327,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
return &OdbcConvert::convDoubleToTinyInt;
case SQL_C_SHORT:
case SQL_C_USHORT:
@@ -359,6 +364,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
return &OdbcConvert::convBigintToTinyInt;
case SQL_C_SHORT:
case SQL_C_USHORT:
@@ -401,6 +407,7 @@
case SQL_C_TINYINT:
case SQL_C_UTINYINT:
case SQL_C_STINYINT:
+ case SQL_C_BIT:
if ( to->isIndicatorSqlDa )
return &OdbcConvert::convTagNumericToTinyInt;
return &OdbcConvert::convNumericToTinyInt;