How To See What Version Of SQL Server Is Running

How To See What Version Of SQL Server Is Running

As an SQL DBA or even an SQL developer, it is crucial to know how to check what version of SQL Server is running. In this article, I will walk you through all the approaches to achieving this. How To See What Version Of SQL Server Is Running Let us discuss each approach individually. Approach-1: … Read more >>

String or Binary Data would be Truncated in SQL

Truncated column in SQL Server

Last week, I worked on a stored procedure in SQL Server. I got an error while working on the query about adding the values in the table. The error came as “String or Binary Data would be Truncated in SQL Server”. String or Binary Data would be Truncated in SQL This is a common error … Read more >>

SQL Server Add Column: ALTER TABLE ADD With Examples

SQL Server add column with ALTER TABLE ADD, shown in VS Code with sqlcmd output

Say your dbo.Customers table already holds five customers from Seattle to Boston, and sales now wants a phone number for each one. In SQL Server you add that column with one statement: ALTER TABLE dbo.Customers ADD Phone varchar(12) NULL; In this tutorial, I’ll show you every SQL Server add column case I run into on … Read more >>

How to use Pgloader to Migrate MySQL Database to Postgres

How to migrate from MySQL to Postgres

MySQL is faster and is used for small organizations but with MySQL, you can’t perform complex and advanced queries. But with PostgreSQL, you can perform such kinds of queries, moreover, it provides analytics or data mining environment. PostgreSQL has abilities for querying optimization, giving better query responses compared to MySQL. There is a tool called … Read more >>

PostgreSQL Insert Into Table Select * From Another Table

PostgreSQL Insert into Table Select from Another Table

In this PostgreSQL tutorial, we will know how PostgreSQL Insert Into Table Select * From Another Table with syntax and examples. PostgreSQL Insert Into Table Select * From Another Table Consider a situation where you need to insert the data from one table to another table, “What will you do?”. You will use the statement … Read more >>

PostgreSQL Joins

Create stored procedure in postgresql using pgadmin

In this PostgreSQL tutorial, we will learn about PostgreSQL Joins. Here we will learn how to use joins in PostgreSQL and PostgreSQL Joins Types. PostgreSQL Joins PostgreSQL joins are used to merge columns from one (self-join) or more tables based on the values of the common columns between related tables. The standard columns are generally the … Read more >>

PostgreSQL Difference Between Two Timestamps

stored procedure parameters system table SQL Server

In this comprehensive PostgreSQL article, I’ll walk you through multiple approaches to finding difference between two timestamps in PostgreSQL, from basic subtraction to more advanced techniques. PostgreSQL Difference Between Two Timestamps Before beginning, we need to be familiar with the PostgreSQL function named EXTRACT(), which retrieves or extracts a sub-field, such as a year, month, or day, from a date … Read more >>

Create a stored procedure in PostgreSQL

PostgreSQL CASE Expression

Stored procedures are essential for efficiently managing database operations. In this comprehensive article, I’ll walk you through everything you need to know about how to create a stored procedure in PostgreSQL. Create a stored procedure in PostgreSQL We can extend the functionality of the PostgreSQL database using various procedural languages, often referred to as stored procedures. With … Read more >>

PostgreSQL Date Add

Postgresql date add

In this PostgreSQL tutorial, we will learn about “PostgreSQL date add,” which means we will add the month, year, and hours to the current date with multiple examples. PostgreSQL date add Before beginning, we need to know that PostgreSQL does not have the DATEADD( ) function like other databases such as SQL, MYSQL, etc. But we can achieve the same result using … Read more >>

PostgreSQL List Databases

postgresql list databases with command line \l

A SaaS startup called me after its Azure bill jumped 40 percent in one month. Nobody knew why. When I connected to the server and ran one command, I found 23 databases. Eleven of them were old test copies, and one held a full production backup that a contractor had restored and forgotten. The team … Read more >>