How is this function suppose to work - clarification needed

Igor Korot 56 Reputation points
2025-08-08T14:02:02.7533333+00:00

Hi, ALL,

In https://learn.microsoft.com/en-us/sql/odbc/reference/syntax/sqlstatistics-function?view=sql-server-ver17#comments at the end of this section. there is a following sentence.

[quote]

If the row in the result set corresponds to a table, the driver sets TYPE to SQL_TABLE_STAT and sets NON_UNIQUE, INDEX_QUALIFIER, INDEX_NAME, ORDINAL_POSITION, COLUMN_NAME, and ASC_OR_DESC to NULL

[/quote]

Can someone please explain what that means?

This API is for retrieving the info about indices, so no table info should be available.

What am I missing?

Thank you.

SQL Server | Other
SQL Server | Other

Additional SQL Server features and topics not covered by specific categories


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.