稀疏列支持 (ODBC)Sparse Columns Support (ODBC)

适用于:Applies to: 是SQL ServerSQL Server(所有支持的版本)yesSQL ServerSQL Server (all supported versions) 是Azure SQL 数据库Azure SQL DatabaseYesAzure SQL 数据库Azure SQL Database 是Azure SQL 托管实例Azure SQL Managed InstanceYesAzure SQL 托管实例Azure SQL Managed Instance 是Azure Synapse AnalyticsAzure Synapse AnalyticsyesAzure Synapse AnalyticsAzure Synapse Analytics 是并行数据仓库Parallel Data Warehouseyes并行数据仓库Parallel Data Warehouse适用于:Applies to: 是SQL ServerSQL Server(所有支持的版本)yesSQL ServerSQL Server (all supported versions) 是Azure SQL 数据库Azure SQL DatabaseYesAzure SQL 数据库Azure SQL Database 是Azure SQL 托管实例Azure SQL Managed InstanceYesAzure SQL 托管实例Azure SQL Managed Instance 是Azure Synapse AnalyticsAzure Synapse AnalyticsyesAzure Synapse AnalyticsAzure Synapse Analytics 是并行数据仓库Parallel Data Warehouseyes并行数据仓库Parallel Data Warehouse

本主题描述对稀疏列的 SQL ServerSQL Server Native Client ODBC 支持。This topic describes SQL ServerSQL Server Native Client ODBC support for sparse columns. 有关演示 ODBC 对稀疏列的支持的示例,请参阅对 具有稀疏列的表调用 SQLColumnsFor a sample demonstrating ODBC support for sparse columns, see Call SQLColumns on a Table with Sparse Columns. 有关稀疏列的详细信息,请参阅 SQL Server Native Client 中的稀疏列支持For more information about sparse columns, see Sparse Columns Support in SQL Server Native Client.

语句元数据Statement Metadata

应用程序参数描述符 (APD) 字段和 SQL_SOPT_SS_NAME_SCOPE 语句属性接受新增的值 SQL_SS_NAME_SCOPE_EXTENDED 和 SQL_SS_NAME_SCOPE_SPARSE_COLUMN_SET。The application parameter descriptor (APD) descriptor field and SQL_SOPT_SS_NAME_SCOPE statement attribute accepts the additional values SQL_SS_NAME_SCOPE_EXTENDED and SQL_SS_NAME_SCOPE_SPARSE_COLUMN_SET. 这些值指定由 SQLColumns返回的结果集中包含的列。These values specify which columns are included in the result set returned by SQLColumns. 有关 SQL_SOPT_SS_NAME_SCOPE 的详细信息,请参阅 SQLSetStmtAttrFor more information about SQL_SOPT_SS_NAME_SCOPE, see SQLSetStmtAttr.

新的实现行描述符 (IRD) (称为 SQL_CA_SS_IS_COLUMN_SET 的只读 SQLSMALLINT 字段)可用于确定列是否是 XML column_set 值。A new implementation row descriptor (IRD), a read-only SQLSMALLINT field called SQL_CA_SS_IS_COLUMN_SET, can be used to determine if a column is an XML column_set value. SQL_CA_SS_IS_COLUMN_SET 接受值 SQL_TRUE 和 SQL_FALSE。SQL_CA_SS_IS_COLUMN_SET takes the values SQL_TRUE and SQL_FALSE.

目录元数据Catalog Metadata

SQL ServerSQL Server SQLColumns的结果集中添加了两个特定列 (SS_IS_SPARSE 和 SS_IS_COLUMN_SET) 。Two SQL ServerSQL Server specific columns (SS_IS_SPARSE and SS_IS_COLUMN_SET) have been added to the result set for SQLColumns.

对稀疏列的 ODBC 函数支持ODBC Function Support for Sparse Columns

以下 ODBC 函数已进行更新,以便在 SQL ServerSQL Server Native Client 中支持稀疏列:The following ODBC functions have been updated to support sparse columns in SQL ServerSQL Server Native Client:

另请参阅See Also

SQL Server Native Client (ODBC)SQL Server Native Client (ODBC)