This is an old revision of the document!



Ispirer Home Page Ispirer SQLWays Product Page - Migration to SQL Server Request SQLWays

System table – syscolumns

Compatability view should be upgraded to catalog view.

Microsoft SQL Server 2000:

 SELECTFROM syscolumns

Microsoft SQL Server 2008:

 SELECTFROM sys.columns

Column convesion:

Microsoft SQL Server 2000 (syscolumns) Microsoft SQL Server 2008 (sys.columns)
id object_id
colid CONVERT(smallint,column_id)
isnullable is_nullable
xtype system_type_id
length case when max_length = -1 then 8000 else max_length end
xprec precision
scale CONVERT(int, nullif(scale,0))
collation collation_name
cdefault default_object_id
xusertype user_type_id
name Isnull(name, '')
CollationPropertyFromId(collationid, 'sqlcharset') CollationProperty(collation_name, 'sqlcharset')

Ispirer Home Page Ispirer SQLWays Product Page - Migration to SQL Server Request SQLWays


© 1999-2024, Ispirer Systems, LLC. All Rights Reserved.