Tag: Database Admin

  • Changing Schemas in SQL Server

    This is a post on how-to on changing the schema of a table in SQL Server, moving it from one schema to another using the ALTER SCHEMA [tableName] TRANSFER SQL statement. During my time as a SQL Database Administrator, assisting with a task like this is a rare…

    Read More


  • Adding & Removing SQL Features via Command

    This post will guide you on how to add and remove features from SQL Server via the command line. The process includes checking installed features, installing a new feature (such as replication), and uninstalling a feature when no longer needed. The following areas will be covered within this…

    Read More


  • Install/Uninstall SQL Server via Command

    This is a post on installing SQL Server via command; I have a Windows Server 2016 Core running on a local Hyper-V test environment, and I’m installing SQL Server 2019, then uninstalling it. There’s 4 parts to this one;# Download a SQL Server ISO. # Mount the ISO…

    Read More


  • Creating a Linked Server for a PostgreSQL Database

    This is a post on how to create a Linked Server to a PostgreSQL database. In my previous post, I created a Linked Server to another SQL Server instance. This time, it’s a link to a Postgres database. I recommend checking out my other post for pre-requisite information…

    Read More


  • Creating a Linked Server to SQL Server

    Linked Servers in SQL Server allow you to query external databases, such as remote SQL Server instances, Oracle, ODBC or MS Access databases. It provides easy query access to another database server for users, however it’s not the most efficient ways to do it. The following steps should…

    Read More


  • Database Growth Events in SQL Server

    When a database file reaches its maximum allocated size, a growth event is triggered to expand the file and allow for more data storage. The size of these growth events can be configured in the database options or by using the ALTER DATABASE statement, as demonstrated below. Properly…

    Read More


  • Setting Maximum Database File Sizes in SQL Server

    Configuring maximum database file sizes in SQL Server is often considered a safeguard or tactical measure rather than a primary strategy. Ideally, you want your databases to grow as needed, without arbitrary limits. However, there are situations where capping database sizes becomes a practical necessity. Why Set Maximum…

    Read More


  • Moving TempDB Files in SQL Server

    It’s a solid best practise to have TempDB files stored in separate drive, away from your C: drive. This is because TempDB can grow very large, very quickly (within minutes); depending on workloads of course, and this can happen on both the TempDB data (.ndf) and log (.ldf)…

    Read More


  • Attaching SQL Databases Without Log Files

    In a perfect world, you’d never lose a database log file. But when the unexpected happens and you urgently need the data from a database, knowing how to attach a SQL Server database without its log (.ldf) file can be a lifesaver. This guide walks you through the…

    Read More


  • Backup & Restore (WITH FILE)

    In this post I’m going to show what the WITH FILE = X option does when backing-up or restoring a SQL Server database. microsoft_documentation The first thing we need to know is that a backup file can contain multiple databases, and even multiples of the same database. If you…

    Read More