Skip to content

db odbcconn: error messages received through SQLGetDiagRec are ANSI - convert them to CP_ACP

Ondrej Pokorny requested to merge fpc-ondrej/source:odbc_error_codepage into main

Error messages received through SQLGetDiagRec are ANSI - convert them to CP_ACP (CP_ACP doesn't have to be ANSI).

This is needed because the exception handling system expects the messages to be in CP_ACP/DefaultCodePage.

E.g. LCL applications change CP_ACP to UTF-8 and then you get corrupted Umlauts in native ODBC error messages.

Merge request reports