 
            From: Piotr Caban piotr@codeweavers.com
--- dlls/odbc32/proxyodbc.c | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-)
diff --git a/dlls/odbc32/proxyodbc.c b/dlls/odbc32/proxyodbc.c index 5287073c162..655d02b871a 100644 --- a/dlls/odbc32/proxyodbc.c +++ b/dlls/odbc32/proxyodbc.c @@ -7367,11 +7367,28 @@ static SQLRETURN statistics_win32_w( struct statement *stmt, SQLWCHAR *catalog, SQLSMALLINT len2, SQLWCHAR *table, SQLSMALLINT len3, SQLUSMALLINT unique, SQLUSMALLINT reserved ) { + SQLRETURN ret = SQL_ERROR; + if (stmt->hdr.win32_funcs->SQLStatisticsW) return stmt->hdr.win32_funcs->SQLStatisticsW( stmt->hdr.win32_handle, catalog, len1, schema, len2, table, len3, unique, reserved ); - if (stmt->hdr.win32_funcs->SQLStatistics) FIXME( "Unicode to ANSI conversion not handled\n" ); - return SQL_ERROR; + if (stmt->hdr.win32_funcs->SQLStatistics) + { + SQLCHAR *catalogA, *schemaA, *tableA; + + catalogA = strnWtoA( catalog, len1 ); + schemaA = strnWtoA( schema, len2 ); + tableA = strnWtoA( table, len3 ); + + ret = stmt->hdr.win32_funcs->SQLStatistics( stmt->hdr.win32_handle, catalogA, SQL_NTS, + schemaA, SQL_NTS, tableA, SQL_NTS, unique, reserved ); + + free( catalogA ); + free( schemaA ); + free( tableA ); + } + + return ret; }
/*************************************************************************