DBA ramblings, tips and scripts to make the work of a DBA smarter and better.
“The more that you read, the more things you will know. The more that you learn, the more places you’ll go.” Dr. Seuss
Feel free to browse the site with the helpful SQL scripts provided. Hope these will help to make your DBA life a little easier.
I have been working as a SQL Server Database Administrator for the past 20 years. I love what I do and the flexibility of a DBA’s work schedule that lets me have a healthy work life balance. All the after hours work as a DBA has its pros and cons but hey – when life gives your lemons (after-hours outage), you make lemonade (just go with the work until it gets resolved…lol)
I am available for any SQL Server Administration consulting work. Please feel free to contact me via the contact us page. Look forward to hearing from you.
Create the user in the master database Now select the user database from the db drop down menu in SQL Server Management Studio Hope this helps you to grant users permission to Azure Synapse Databases.
Database Mail Troubleshooting I use the following scritps to troubleshoot database mail issues. –Get a list of email sent itemsSELECT * FROM dbo.sysmail_sentitems –Another version of the script to get a list of email sent itemsUSE msdbSELECT sent_status, *FROM sysmail_allitemsorder by send_request_date desc –Check to see if broker service is enabledSELECT is_broker_enabled FROM sys.databases WHERE […]
I received a request to export data from a table in a database in Production to a similar table in a database in the Development environment. I used the export/import wizard thru SQL Server Management Studio but my export was failing giving me an error that the data cannot be copied because Foreign Key was […]
I rdp’d to the sql server and to check which sql services are installed on the server – I tried to open SQL Configuration manager but I was unable to open SQL Server Configuration Manager. When I clicked on Configuration manager I get the error: Cannot connect to WMI provider.You do not have permission or […]
If a non-sysadmin users requests permission to modify sql job schedules that are not the owner of then you can do the following: Grant the user execute permission to sp_update_jobsp_update_jobschedulesp_update_jobstep Here is the TSQL for it: GRANT EXECUTE ON sp_update_job to [username]GRANT EXECUTE ON sp_update_jobschedule to [username]GRANT EXECUTE ON sp_update_jobstep to [username] I also tried […]
There are occasions when database users will reach out to me get elevated database permissions to run DMVs. Members of sysadmin roles can view the results of Dynamic Management Objects but sometimes it There are occasions when database users will reach out to me get elevated database permissions to run DMVs. Members of sysadmin roles […]