Skip to Content.
Sympa Menu

freetds - [freetds] Obtaining diagnostic messages

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Bruce Seely <bseely AT stsci.edu>
  • To: "freetds AT lists.ibiblio.org" <freetds AT lists.ibiblio.org>
  • Subject: [freetds] Obtaining diagnostic messages
  • Date: Mon, 27 Jul 2020 17:55:54 +0000

How can I get the error reason when an error code is returned by a call to
SQLColAttribute?

SQLColAttribute is called with these arguments:
SQLHSTMT StatementHandle, odbc_hstmt
SQLUSMALLINT ColumnNumber, 1
SQLUSMALLINT FieldIdentifier, 1011
SQLPOINTER CharacterAttributePtr, STACK-ALLOCATED
(SHORT-SIMPLE-ARRAY FOREIGN (65))
SQLSMALLINT BufferLength, 255 (also tried 65)
SQLSMALLINT * StringLengthPtr, STACK-ALLOCATED (SHORT-SIMPLE-ARRAY
FOREIGN (2))
SQLLEN * NumericAttributePtr); 0

The returned value is -1.

When pending messages are retrieved using SQLGetDiagRec, no messages are
found.
What can I do to determine why the call is failing?

Thank you,
Bruce




Archive powered by MHonArc 2.6.24.

Top of Page