Skip to main content
Home
Blog

Main navigation

  • Home
User account menu
  • Log in

Breadcrumb

  1. Home
  2. Forums
  3. Knowledge Base
  4. How-To

Do you ever wish to be able to "describe" a table in MSSQL?

By ongetc , 26 February, 2017

It is not available in MSSQL but it can be done with the help of function and store procedure.

In this article, I will show you how it can be done.

First create a XML variable like this:

SELECT @xmlFldList = (select * from ftvDescribe('tSomeTable') for xml raw)

Then call the spDescribeSchema to describe the table.

declare @SchemaInText varchar(max) exec dbo.[spDescribeSchema] @xmlFldList, @SchemaInText output

Please see the actual code of these calls above in this How-To

Forums
How-To

Reseller hosting (free)

Hosting24 (w/ ssh)

A2 Hosting

Monthly archive

  • February 2019 (1)
  • December 2020 (224)
  • January 2021 (168)
  • March 2021 (1)
  • June 2026 (1)

Pagination

  • Previous page
  • 2

Popular content

Last viewed:

  • Tiki
  • PHP-Fusion
  • script.aculo.us
  • Telecommunication Relay Services
  • Aardvark Topsites PHP
  • TheHostingTool
  • dotProject
  • Slack
  • KevLinDev - Tutorials
  • How to solve missing jboss-boot.jar?

User login

  • Reset your password