Category Archives: SQL Administration

The SQL Administration category groups articles focused on MS SQL Server, specifically server (database, tables) administration, maintenance, and troubleshooting.

Don’t miss out from category:

Bulk Copy Program (BCP) Utility – Fast Bulk Import and Export in SQL Server

BCP is a utility that is installed by default with SQL Server editions and is used for bulk import or export of a large volume of data in user-defined formats. This utility is optimized for large data transfers either between SQL Server instances or between a SQL instance and a text file. The utility is… Read More »

SQL Server Table and Index Compression (Data Compression), Pros/Cons

Table and index compression is a functionality that has been available in various SQL Server editions for a while. It has been available in all editions, including SQL Server Express (for free), since version SQL Server 2016. Data compression allows you to save storage space significantly. This, of course, saves enterprise resources, such as hardware… Read More »

Data Masking in SQL Server – How to Hide Data in a Specific Column

Data masking is a feature that allows you to completely or partially mask selected data in a database. Access to unmask the data can also be granted or revoked for individual users. Data masking and anonymization have become increasingly important topics, especially with the introduction of GDPR regulations by the European Commission, which require greater… Read More »

SQL | SEQUENCE (ID Generation) and CACHE settings

For generating IDs (primary keys) in application databases or surrogate keys in data warehouses, there are several approaches. GUIDs or numeric IDs are mostly used. GUIDs are mainly used in application databases and are generated, for example, using the NEWID() function. This has its advantages and disadvantages. The biggest disadvantage is poor SQL query performance… Read More »

Installing SQL Server from the command line (cmd)

Aside from the standard method of installing SQL Server via the classic visual interface, there is also the option to install SQL Server from the command line or PowerShell. This is useful when you regularly perform multiple installations with similar configurations and want to dynamically define instance names, service accounts, or installation directories. Additionally, there… Read More »

Installation of MS SQL Server – Planning, Hardware, and Software Requirements

Installation of MS SQL Server involves a lot of work before an IT specialist can actually start the installation process. Before we address the software and hardware requirements, we need to consider one thing: what edition of SQL Server we will actually need, depending on the features of SQL Server we intend to use. Hardware… Read More »

AdventureWorks Sample Database in SQL Server locally or in Azure

AdventureWorks databases from Microsoft are the most popular sample databases for developers, database administrators, or simply for students looking to learn something about SQL Server and database management. In this article, we will take a look at the available variants of Adventure Works databases, but more importantly, I want to highlight the possibility of connecting… Read More »

SQLCMD (Server command line) – Run SQL query via cmd

In this short article I will introduce the possibility to run a sql script outside of SQL management studio using SQL server command line utility (sqlcmd for short). This utility allows you to work with SQL server using the command line. The use are obvious and include working with SQL from different applications. How to… Read More »

Mac M1/Apple Silicon – SQL Server Developer – Installation Guide

I recently purchased a new Macbook Air with Apple Silicon M1 CPU architecture (ARM). From the first time everything was fine – super experience when unboxing, everything tuned to the smallest detail, huge performance, battery lasts 8 hours on a single charge without losing performance when unplugged. But… As a Business intelligence developer and financial… Read More »

SQL Index Fragmentation – Example + SQL Scripts

Table Indexes are a fundamental pillar of optimizing SQL queries in a database. They significantly speed up read operations. Unfortunately, over time, indexes get fragmented, and the order of indexes deteriorates. Index fragmentation occurs because records are gradually inserted or deleted from a table, and indexes are not optimized afterward. This means that individual index… Read More »