2002-11-05
592 reads
2002-11-05
592 reads
Below is a SQL Server 2000 query to return all columns that are primary keys to tables in a database
2002-11-01
223 reads
This procedure was created to automate the dropping of statistics on a user specified table. Very simple code, but handy if the need is there.Replace 'tablename' throughout script with the name of the table intended to temporarily house the statistics name(s).
2002-11-01
1,059 reads
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 […]
2002-10-31
353 reads
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 […]
2002-10-31
643 reads
The stored proc FindObjByColumn_sp, while simple, is extremely useful when making database changes or for any reason that you need to find any tables and stored procedures that contain a particular column. It searches the system tables of a database to find the object containing the column. In addition, the procedure automatically adds a wildcard […]
2002-10-31
437 reads
Use this script to create a warm standby database server for all your user database. This new version has a new feature to allow the standby database to be in a ready-only mode so that users can access it. You can change the job schedule to suit your requirement. One bug has been fixed that […]
2002-10-31
293 reads
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 […]
2002-10-31
809 reads
This is not an original script - but one I modified from an article by Darren Green on databasejournal.com (02/21/2000). His original script changed the owner of all DTS packages owned by @old_owner to be owned by @new_owner. This script will change the owner of the most recent version of a specific DTS package (@p_name) […]
2002-10-29
497 reads
Here is another Number of Days in the Month function for SQL Server without the use of Case or if statements. It uses the DATEPART and DATEADD built-in functions.
2002-10-28
420 reads
No Scooby-Doo story is complete without footprints leading to a hidden passage. In SQL...
By James Serra
A bunch of new features for Microsoft Fabric were announced at the Microsoft Fabric Community...
By Steve Jones
I saw an article recently about implicit transactions and coincidentally, I had a friend...
We’re running SQL Server 2019 with database compatibility level 150, and after recent tuning...
Comments posted to this topic are about the item Changing the Recovery Time
Comments posted to this topic are about the item Getting More Time from AI
I want to change the recovery time for a database running on SQL Server 2022. What are my options for setting the value in my ALTER DATABASE statement. If I run this code, what can I use in place of the xxx to define what 12 means?
ALTER DATABASE Finance SET TARGET_RECOVERY_TIME = 12 xxx;See possible answers