Out of memory exception in SQL Server Management Studio (SSMS) while opening ‘restore database’ page

Recently, my colleague came across a problem while trying to open the ‘Restore Database’ page in a SQL server database management tool , SSMS. Whether he right-clicked on the ‘Databases’ folder or on a specific database, the page wouldn’t open and eventually, he received an “out of memory” error message. Exception of type ‘System.OutOfMemoryException’ was … Read more

Using Snapshot Replication for Schema Transfer/Refresh Only

Snapshot replication distributes data exactly as it appears at a specific moment in time and does not monitor for updates to the data. When synchronization occurs, the entire snapshot is generated and sent to Subscribers. The snapshot process (which creates a copy of all of the objects and data specified by a publication) is also … Read more

Cleanup Log-shipping configuration through TSQL

For database migrations, DBAs many times configure log shipping from old server to new server to reduce the downtime required during the cutover. Below approach is followed to perform such migrations As in above approach, we offline our databases on primary instance , we can no longer remove the log shipping configuration using GUI through … Read more

Configure non-default PostgreSQL instance for automatic start on machine start in RHEL

Due to policies for Red Hat family distributions, the PostgreSQL installation is not enabled for automatic start or have the database initialized automatically. Database cluster need to be initialized manually post installation. Once initialized, data directory will get created but still PostgreSQL will not be running. We can use ‘systemctl’ service to enable and start postgresql-<versionnumber> … Read more

Código de error: 22903, texto: “Ya hay otra conexión ejecutando ‘sp_replcmds’ para la captura de datos modificados en la base de datos actual.”

Recientemente me enfrenté a un escenario muy interesante en el que para una base de datos se habilitaban tanto la captura de datos modificados como la replicación transaccional. Según la documentación de MS, ambas funciones pueden funcionar juntas, pero debemos tener algunas cosas en cuenta al implementar ambas funciones juntas en una base de datos. En … Read more

Compresión de datos en SQL Server

A medida que las bases de datos crecen cada vez más, un desafío al que se enfrentan los administradores de bases de datos es administrar el tamaño de sus bases de datos. Las bases de datos más grandes pueden consumir más espacio en disco, memoria y potencia de procesamiento, lo que puede resultar en tiempos de … Read more

Data Compression in SQL Server

As databases grow larger and larger, one challenge that database administrators face is managing the size of their databases. Larger databases can consume more disk space, memory and processing power, which can result in longer backup and restore times, slower query performance, and increased storage costs. One way to address this issue is through data … Read more

How to run a script on all databases that are either AG primary or standalone in SQL instance

In this article we will discuss on how to run a script on all databases that are either AG primary or standalone in SQL instance.

Script to find space utilization in each data file and log file

Script to find space utilization in each data file and log file. This will be useful while troubleshooting data and log file full issues.

Script to find last successful run of SQL agent jobs

Script to find last successful run of SQL agent jobs.