• Interests: Cricket, Astronomy, Robotics, Reading and RPG Games

Technical Article

Set logging properties for group of DTS packages

This script will set the Logging properties for a group of DTS packages. To run this script stand-alone, you'll need to set 6 variables. sSvr, sDb, sUid, sPwd, iSec and sPkgMatch. If you use this script in a DTS package, you can assign the values from Global Variables. The sPkgMatch variable is used as a […]

You rated this post out of 5. Change rating

2003-12-01

417 reads

Technical Article

Delete old versions of DTS packages

This script will remove old versions of DTS packages. It accepts a single parameter which is used as a filter criteria on the package name. It will also remove package log records for the version that is deleted.EXAMPLE: EXEC usp_DelOldDTSPkgVersions @vcrPkgName = 'Devel'This will delete old versions for packages that have 'Devel' in the nameQuestions […]

5 (2)

You rated this post out of 5. Change rating

2002-11-30

1,138 reads

Technical Article

Execute DTS package using OA procedures

This script will execute a DTS package using the sp_OA stored procedures. It accepts six parameters which specify the server name, security mode flag, userid, password, package name and optional package password.Eg:For SQL SecurityEXEC usp_ExecDTSPackage @vcrSrvr='Server', @bitIntSec=0, @vcrUID='UserID', @vcrPWD='Password', @vcrPkgName='Package Name', @vcrPkgPWD='Package Password'For Windows SecurityEXEC usp_ExecDTSPackage @vcrSrvr='Server', @bitIntSec=1, @vcrPkgName='Package Name', @vcrPkgPWD='Package Password'It uses a function […]

You rated this post out of 5. Change rating

2002-10-31

349 reads

Technical Article

Find and Replace VBScript within DTS Package

This script will find and replace specified text within all ActiveXScript tasks with a certain text string in the description. It was designed on SQL 2000, but I think it will run on SQL 7 as it doesn't reference any SQL 2000 specific properties. It opens a package object and then loops through the steps […]

You rated this post out of 5. Change rating

2002-10-31

619 reads

Technical Article

Report DTS Error Code and Description

This stored procedure extract the error code and description form the DTS package log tables in the msdb database.You just pass it the package name, step name and the time that the step started ( because you could end up with many entries in the log ) and it will return the Error Code and […]

You rated this post out of 5. Change rating

2002-10-25

2,668 reads

Technical Article

Return formatted datetime as a string

Pass a datetime value and receive back a formatted string. Much like the Format$ function in Visual Basic.I put this together to provide a date string to add to filename. Also handy when you are creating text files that require datetime data to be output in weird character formats like yyddmm or yyyymm.eg: fnDate2Char(GetDate(), 'dmy', […]

You rated this post out of 5. Change rating

2002-02-27

821 reads

Technical Article

Re-create Transaction log file

This stored procedure detaches and re-attaches a database without specifying a filename for the transaction log. This causes SQL Server to create log file with default size of 512kb.After playing around with SHRINKDATABASE, SHRINKFILE, forcing the virtual log to wrap around, etc... I found this was the quickest and most reliable method of reclaiming the […]

You rated this post out of 5. Change rating

2002-02-25

2,605 reads

Blogs

SQL Data Pipelines: The Ultimate Guide to Streamlining Your Data Flow

By

Want to build a data analytics foundation that transforms raw data into valuable business...

Using SQL Compare in Read-Only Databases

By

Recently a customer asked if SQL Compare and SQL Data Compare can be used...

T-SQL Tuesday #179 Roundup: The Data Detective Toolkit

By

Earlier this month, I hosted the monthly T-SQL Tuesday invitation in which I asked,...

Read the latest Blogs

Forums

Date Type ETL Question

By Coffee_&_SQL

I'm not sure that I'm posting this in the right section, so please mods...

Possible oddity in msdb.dbo.backupset

By richardmgreen1

Hi all   I've written a script to keep track of how long backups...

Operand data type varchar is invalid for sum operator

By yrstruly

I have this view [dbo].[Asset Metrics - Client(Rama -Client-Test)], which makes use of multiple...

Visit the forum

Question of the Day

Data Migration Assistant Sources

In the current (Sep 2024) Data Migration Assistant, what are the possible sources for on-premises SQL Server instances?

See possible answers