Easysoft ODBC-ODBC Bridge

Why do I get "Incorrect Syntax near the Keyword 'by'" error message when calling SQLDescribeParam in the MS SQL Server ODBC driver?

Last Reviewed:
4th January 2024

When calling SQLDescribeParam in the Microsoft SQL Server ODBC driver, you get an error return with the diagnostic text:

"Incorrect Syntax near the Keyword 'by'"

This was a bug in MDAC 2.6 and is fixed in MDAC 2.6 sp1.

It happens if you have a column named "c", "ca" or "cas" and you call SQLDescribeParam, because the driver is checking for a CASE statement and does the check incorrectly.

Applies To

Knowledge Base Feedback

* Did this content help you?
* Please select one option based on your first choice:

(* Required Fields)