PowerShell – Email All Users Connected (Logged In) To A SQL Server Instance

As a DBA, when I have to do an emergency restart of a SQL Server instance or the host itself, the first thing I do is to check who is connected so that I can notify them (at least the ACTIVE users). We do have a system where we keep the app/database/owner information but notifying … Continue reading PowerShell – Email All Users Connected (Logged In) To A SQL Server Instance

PowerShell – Get Files Modified In A Certain Date Range And Copy/Delete/Zip…whatever

Today a good friend of mine, DamuĀ asked for a function that could copy files from a source to destination based on modified date criteria. Although it could be easily accomplished in the command-line itself, I took upon myself as an exercise to create a wrapper function to do the same in case he wants to … Continue reading PowerShell – Get Files Modified In A Certain Date Range And Copy/Delete/Zip…whatever