Technical Article

How to get ColumnNames, datatypes and length

This is a followup to the script submitted by srallapalli. One can return a record set of all tables in a database using the following:USE MyDatabaseSELECT so.name AS TableName, sc.name AS ColumnName,  st.name AS ColumnDatatype,  convert(int, sc.length) AS ColumnLength FROM syscolumns sc, sysobjects so , systypes st WHERE so.type='U' AND OBJECTPROPERTY(so.id,'ismsshipped') = 0 AND sc.id=so.id […]

2003-05-10

138 reads

Blogs

Types of data consulting engagements and what you can expect from them

By

There are multiple ways organizations can engage with a data (DBA/analytics/data architect/ML/etc.) consultant. The...

Daily Coping 6 Dec 2022

By

Today’s coping tip is to find a new way to tell someone you appreciate...

What’s next: Job search burnout

By

I was given 4.5 months notice this past June and was fortunate to find...

Read the latest Blogs

Forums

Stairways to ScriptDOM Level 4 – Finding Nuanced Patterns

By Diligentdba 46159

Comments posted to this topic are about the item Stairways to ScriptDOM Level 4...

The Availability Group Secondary Connection

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Availability Group Secondary Connection

SSRS Expression Error

By Jeffs1977

I am getting the following error when I try to use the Expression below....

Visit the forum

Ask SSC Logo Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers