T-SQL

Technical Article

Getting Information about Database Objects

  • Script

It is sometimes necessary to have information regarding the database objects like stored procedures and triggers for e.g. we need to get information about a stored procedure like what paramters it has and so on.The sp_help system stored procedure comes in handy.What this store procedure does is that it returns result set. The result will […]

You rated this post out of 5. Change rating

2003-08-07

176 reads

Technical Article

Group numbering

  • Script

An easy way to organize the data by groups of sequential numbers. This is very helpful for splitting up a large file into numerous smaller files. You can then create the smaller files by filtering for the row number per file.

You rated this post out of 5. Change rating

2003-07-09

214 reads

Technical Article

Load data from text file with variable columns

  • Script

This script loads from a formatted text file (E.g. tab delimited) with variable number of columns using BULK INSERT. For instance, the file may have any number of columns and next load (seconds later) the same file may have a different number of columns. This script reads the first line (column names) extracting the names […]

You rated this post out of 5. Change rating

2005-03-01 (first published: )

971 reads

Technical Article

Show all User-Defined Datatypes for all Databases

  • Script

This procedure displays all user-defined datatypes in all databases on a server.  Another example of the power of dynamic T-SQL, this procedure dynamically generates SELECT statements for the systypes tables in each database and UNIONs them together so that they display in one recordset.

You rated this post out of 5. Change rating

2003-05-30

151 reads

Technical Article

Table Pivoting revisited

  • Script

A lot of table pivoting scripts use cursors to reach the  desired results, but SQL scripting was developed to be utilized in a data set environment rather than sequential step-thru scripting.Normally, there are 3 types of Table Pivoting - 1) column explicit 2) column implicit and 3)single column.  COLUMN EXPLICIT will place the row value […]

You rated this post out of 5. Change rating

2003-05-29

412 reads

Blogs

Check Azure SQL DB Space Used

By

A couple of days ago I was doing some cleaning on some Azure SQL...

Use a slicer to filter a visual based upon a measure in Power BI

By

Have you ever wanted to filter a visual by selecting a range of values...

Deleting Stale Local Database Git Branches with SSMS–#SQLNewBlogger

By

I wrote a post recently about pruning branches in git. That’s part of the...

Read the latest Blogs

Forums

SSRS Web Service URL - getting rid of HTTP

By cphite

Not sure if this is the place to ask, but will give it a...

SQL Server software and windows version compatibility level

By Abhishek

Is there a specific platform or website where I can verify the compatibility between...

Truncate tables where Referential Integrity exists

By Perry Whittle

Comments posted to this topic are about the item Truncate tables where Referential Integrity...

Visit the forum

Question of the Day

Post Restore Tasks for the Resource Database

I backup the Resource database from my SQL Server 2022 instance. I then install CUs 1, 2, 3, and 4. I have an issue and need to restore my Resource database from backup. Is there anything I need to do after restoring this database?

See possible answers