T-SQL

Technical Article

Stored Proc with optional parameters

  • Script

Sometimes people want a Stored Proc with optional parameters. A lot of times people will use a coalesce for this. The problem with optional paremeters is that the query plan will never be an exact mach for that specific query. ( You never know what paremeters are filled..... )To solve this problem look at the […]

You rated this post out of 5. Change rating

2002-12-06

441 reads

Technical Article

Converting Binary data to a Hex Character String

  • Script

Occassionally you might want to convert a binary number into some printable string.   This would allow you display some meaning fully numbers hex characters, instead of just some unreadable garbage.  This script takes a binary field, of basically any length, and converts it, character by character, to a character string.  The character string will contain […]

You rated this post out of 5. Change rating

2002-11-07

455 reads

Technical Article

sp_DBCompare

  • Script

This simple script make a comparison between two given database. It compare: The table present in both database            The data type, lenght, nullability, precision for each table.            The object present in both database. The StoredProc is able to compare database across different server, simple make […]

You rated this post out of 5. Change rating

2002-10-31

805 reads

Technical Article

Latest DTS Package Log

  • Script

This script returns the latest package log for the DTS package specified in the @package_name variable.  The interface for viewing DTS package logs through Enterprise Manager is limited in the fact that it doesn't provide textual descriptions of the values for the Step Execute Status and Step Execute Results.  This makes it difficult to trace […]

You rated this post out of 5. Change rating

2002-10-22

619 reads

Technical Article

Get Number of Days in month

  • Script

Have seen existing scripts to work out number of days in month. They tend to work out the month, and then whether it's a leap year.Another approach is to take the date passed in, find the first day of the next month, and then use Datadd to take off one day, ie: last day of […]

4 (1)

You rated this post out of 5. Change rating

2002-10-17

416 reads

Technical Article

Create And Execute Table Script (SQL Server 2000)

  • Script

This SP will only work on SQL Server 2000 and can be placed in your master database. sp_CreateAndExecTableScript is designed to script one table and create an identical table. I designed it to use with DTS packages so that I can create an identical table with a different name, pump data into the table and […]

5 (3)

You rated this post out of 5. Change rating

2002-10-15

2,517 reads

Blogs

Another AI Faux Pax

By

I was experimenting with a local model (article) and as a part of this,...

Monday Monitor Tips: Using the PowerShell API

By

Redgate Monitor has grown tremendously from its early days and I find many customers...

Data Governance: The Invisible AI Accelerator

By

The post Data Governance: The Invisible AI Accelerator appeared first on Joyful Craftsmen.

Read the latest Blogs

Forums

Problem with the dll (version 1.2) of an Extended Stored Procedure with SQL Serv

By SKEITA

SQL Server 2022 16.0.4165.4 Windows Server 2022 Datacenter 21H2 20348.2849 Our Extended Stored Procedure...

PK violation in replication but only one subscriber

By cphite

We have a publication with three subscribers; it's basically a part list with around...

Recovery Takes 10-20 mins with ADR enabled

By VastSQL

Hi Experts, I have database about 300GB in size with ADR enabled but after...

Visit the forum

Question of the Day

Data API Builder Operations

What types of database operations does the Data API Builder support?

See possible answers