As you know, if you've written even a modested amount of UDFs, they like to be deterministic in fact they insist on it, and the most undeterministic value you are likely to want is today's date. Yes, you can use calls to extended stored procedures but I like the simplicity and versatility of this solution.The […]
2004-09-14 (first published: 2004-06-17)
298 reads
This is a fairly basic script that gets back a list of steps within dts packages that failed within the last 24 hours. The reason I wrote this script, is that if you call a dts package from a dts package on another server via a scheduled job on that same server, both the package […]
2004-09-13 (first published: 2004-06-16)
129 reads
This script is supported only in SQL SERVER 2000, This shows only indexes created by users in tables.Parameter @tabela--> You can put the table name and get the information about users indexes in this table.OrYou can put nothing (NULL) and see all tables on the schema and how many indexes each table have.
2004-09-10 (first published: 2004-06-08)
238 reads
Uses the sysjobs and the sysjobhistory tables in the msdb database to determine if ONLY THE MOST RECENT RUN of any job on the server failed.
2004-09-09 (first published: 2004-06-02)
253 reads
Given a backupfile with a lot of sequential log-backups, this script automatically restores just those backups out of the file, which are necessary to bring the database up to a given timelag relating to the original database.Params are path to backupfile, name of the db to restore to, timelag in minutes.
2004-09-08 (first published: 2004-05-28)
1,633 reads
I wrote this to backup to a network share you can set the backup to spool to the local disk first then it will move it to another drive or to a unc just fine. Directory to hold and move to are not optional but if you set them to the same path it won't […]
2004-09-06 (first published: 2004-05-27)
386 reads
Modification of DR_Script_Logins.sql by Bruce Canady.Puts out a script to add new logins or change the password of existing logins.I insert the output into a table in my production-db. insert database.dbo.login_table exec master.dbo.dr_script_loginsThat way its backed up with the data, and the logins can be restored anywhere by the script i added at the […]
2004-09-03 (first published: 2004-05-26)
2,521 reads