Monday, February 27, 2012

How can I get the SQL Server 2000 Column Description

How can I get the SQL Server 2000 Column Description within ADO.NET 2.0?

BR / Chris

Hi

The following lines steer U.

Dim _Con As New SqlConnection("...")

Dim _Com As New SqlCommand("Select * from ...", _Con)

_con.Open()

Dim _DTable As DataTable = _Com.ExecuteReader.GetSchemaTable()

DataGrid1.DataSource = _DTable

Pandian S

|||

ColumnName ColumnOrdinal ColumnSize NumericPrecision NumericScale IsUnique IsKey BaseServerName BaseCatalogName BaseColumnName BaseSchemaName BaseTableName AllowDBNull ProviderType IsAliased IsExpression IsIdentity IsAutoIncrement IsRowVersion IsHidden IsLong IsReadOnly DataTypeName XmlSchemaCollectionDatabase XmlSchemaCollectionOwningSchema XmlSchemaCollectionName UdtAssemblyQualifiedName NonVersionedProviderType unit_id 0 8 19 255 unit_id 0 bigint 0

Using the GetSchemaTable method does not work. Above is a listing of what I retrieved for a database table, where a description for unit_id should exist.

/Steffan

No comments:

Post a Comment