Shrink DBs - Job Script

I'm posting this job script because it gets used by my scheduler script. It simply enumerates through each database on the server, and then executes a DBCC SHRINKDATABASE. The only wrinkle here is that I have it do a quick check to make sure that certain jobs are not already running.

2002-01-04

1,128 reads

Transaction Logs - Job Script

I've included this job script, because it is used by the scheduler scripts that I've also posted. This job is a little more involved than most may need... It first checks to see if certain jobs are running. Is so, it waits for a while, and then checks again. After that it drops the existing […]

2002-01-04

1,088 reads

Check Jobs Current State

I created this script in an attempt to better automate many different jobs that run each morning, as part of a datawarehouse build. I use it to not only tell me what jobs are currently running (so that I can manage how many I would like to run at a time), but what happened to […]

5 (2)

2002-01-03

1,232 reads

Blogs

Continuous integration and delivery (CI/CD) in Azure Data Factory using DevOps and GitHub - Part 2

By

(2020-Jan-28) This blog post is a followup to my previous post about DevOps (CI/CD) for...

Extended Events Misperceptions: Profiler is Easier, Part 2

By

I wrote a short blog post about the misperception that Profiler was easier than...

CREATE TABLE MyTable (Col1 CHARACTER VARYING (50))

By

If you read the title to this post and your first thought was That’s...

Read the latest Blogs

Forums

Fastest way to load a CSV file in SQL Server Table

By SQL Kidu

What is the fastest way to load a file in SQL Server Table ?...

Replication question

By pani

Im an Oracle DBA by trade and been tasked with setting up transaction replication...

Software to send Report

By VastSQL

Hi Experts, Currently we are using SQL Server and Database Mail to send reports...

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers