Scripts

Technical Article

Record Count for Tables

This script was created for an Oracle to SQL 2005 migration. It creates a table, and then populates it with the record counts for each table in a given schema. (You will need to replace the xxxx text with your schema name for it to work). I prefer populating a table with this data, then […]

2 (1)

You rated this post out of 5. Change rating

2007-09-24 (first published: )

1,017 reads

Technical Article

proc to order xp_enumerrorlog

this is a quick stored procedure I put together when trying to find a log for a particular day (xp_enumerrorlogs returns the archive is as a varchar, so 1 is followed by 11, 12 etc rather than 2) sp_display_errorlogs with no parms returns output in archive id order. if the parm 'size' is passed in, […]

You rated this post out of 5. Change rating

2007-09-21

764 reads

Technical Article

A Simply way to implement Audit Trail in SQL 2005

In a recent project, I need to record audit trail for some tables (for Insert, Update and Delete).Using SQL 2005's XML datatype and the XML support it is very covenienet to use triggers to perform the audit trail requirement. I create one table (Table_Audit)  to hold all audit trial data. One stored procedure is created […]

5 (2)

You rated this post out of 5. Change rating

2007-09-20

3,310 reads

Technical Article

Delete constraints - SQL Server 2005

This script will DELETE ALL constraints within the database that you define and in the following order: Foreign Key, Primary Key and then Unique Key.CAUTION:This script does not print out the ALTER TABLE statements, it drop the constraints immediately, therefore backup your database before testing or using this script. I ran the script below and […]

5 (3)

You rated this post out of 5. Change rating

2007-09-19 (first published: )

4,077 reads

Technical Article

_Select Update

I made some modifications to D Simmon's original sp.  1. I added dynamic feature to query tables in other databases (not linked servers) from one sp. I know dynamic sql isn't preferable in most cases but this is the route I took for this.  2. I enabled table name to be sent with owner qualification […]

You rated this post out of 5. Change rating

2007-09-18 (first published: )

602 reads

Blogs

Book Review – Microsoft Power BI Performance Best Practices

By

I was asked to do a review of the book Microsoft Power BI Performance...

SQL Server Distributed Availability Groups and Kubernetes

By

A while back I wrote about how to use a Cross Platform (or Clusterless)...

Webcast Tomorrow on SQL Server Disaster Recovery

By

Tomorrow, November 19, 2024, at 1 PM EST, I'm giving a webcast on SQL...

Read the latest Blogs

Forums

Stairway to Snowflake Level 5 - Using Snowflake with SnowSQL and Visual Studio Code

By Mike McQuillan

Comments posted to this topic are about the item Stairway to Snowflake Level 5...

A Strange Result

By Steve Jones - SSC Editor

Comments posted to this topic are about the item A Strange Result

Possible SQL 2014 to 2016 Issue - Some Application Functions Slow/Failing

By Allenii02

First time here...hoping I can find some direction and answers so I can devise...

Visit the forum

Question of the Day

A Strange Result

What does this code return in SSMS 20 from SQL Server 2019?

select '|' + CHAR(0)+'abc' + '|';

See possible answers