Author: Peter Whyte

  • The USE Database Statement in SQL Server

    The USE [database] command in SQL Server is used to switch the context to a specific database when running queries. This is useful when you need to work with multiple databases or change the active database during a session. When to use this statement:– When you want to…

    Read More


  • Installing oh-my-posh On Windows

    Oh-my-posh is a theme engine for PowerShell that enhances your terminal with custom themes. It integrates with posh-git to display useful indicators for Git repositories, failed commands, and admin status. This quick guide will walk you through installing Oh My Posh and setting a theme using Choco on…

    Read More


  • How to Install Windows Terminal

    Windows Terminal (WT) is a modern command-line application for Windows that supports various shells such as PowerShell, Command Prompt, and Windows Subsystem for Linux (WSL). It offers a rich user experience with features like tabs, panes, and a customizable interface. Other benefits of Windows Terminal include Unicode /…

    Read More


  • How to Install Posh-Git on Windows

    posh-git is a PowerShell module that enhances your command line experience by displaying Git status information and providing tab completion for Git commands. This guide will show you how to install Posh Git on Windows using the Chocolatey Package Manager. As an afterthought, I’ve added notes at the…

    Read More


  • Install Chocolatey on Windows

    This post is a guide on installing the Chocolatey package manager on Windows by running a PowerShell command. Chocolatey allows you to manage software packages on your system with simple ‘choco’ commands. In this post after I install Chocolatey I’m installing a GUI to view all installed packages.…

    Read More


  • Disk Usage by Top Tables Report in SQL Server

    The Disk Usage by Top Tables Report in SQL Server is a quick way to get the sizes of all tables within a database. It’ll show all tables largest to smallest tables by total size on disk. If you notice that a database is growing larger in size,…

    Read More


  • Change Git Remote URL to SSH from HTTPS

    This post is a guide on how to change Git from using SSH to HTTPS for authentication. Using SSH for your version control system is more efficient as we do not have to enter a password every time we need to contact the remote repository. You should have…

    Read More


  • List all Tables & Columns in Redshift or Postgres

    If you need to list all tables and columns in Redshift or Postgres, this guide provides a SQL script to retrieve schema details across all databases. Redshift is based on (forked from) PostgreSQL, meaning many core SQL commands work similarly in both. However, Redshift introduces key differences, such…

    Read More


  • Creating a New User in Redshift and Promoting to Superuser

    This article provides a step-by-step demo for creating a new User in Redshift and promoting it to a Superuser. I’ll include useful tips, best practices, and links to AWS Docs to help streamline the process. In Amazon Redshift, a Superuser has the highest level of permissions, equivalent to…

    Read More


  • Drop Users in RedShift

    Dropping users in Amazon Redshift is a simple task, but sometimes you may encounter an error message if the user you are trying to drop is an owner of an object in the database, such as a schema, table, or view. When this happens, you will see one…

    Read More