How to use the PostgreSQL PDO Driver with PHP – Part 5

Introduction This is part five in the tutorial series explaining how to use PHP with the PostgreSQL PDO driver. Part four of this article covered how to retrieve rows from the tblemployee in the PostgreSQL testDatabase. This final part in the series will cover how to delete both a specific data row and all the … Continued

How to use the PostgreSQL PDO Driver with PHP Part 4

Introduction This is part four of the tutorial series explaining how to connect PHP to PostgreSQL with the PDO driver. The last section of the tutorial covered how to update data in the PostgreSQL database in PHP with the PDO driver. This part four will explain how to query data. It is strongly suggested that … Continued

SQL Rank

Introduction PostgreSQL, the popular object-relational database management system (ORDBMS), has several powerful functions to assist application developers and DBAs in managing their data expeditiously. Among the most helpful functions in PostgreSQL is SQL RANK(). When you use it to query, you have the ability to separate the rows of the result response. Each row can … Continued

SQL Coding Test

Instruction In this coding test, we will be providing you with code to construct an SQL schema. Some database operations will have to be performed on the schema and answers to those will be provided in the end. Schema Setup Code Run the below code in SQL: 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566CREATE SCHEMA SCHOOL; CREATE TABLE Teachers ( T_id … Continued

SQL SELECT AS

Introduction In this article, we will be discussing the SQL SELECT AS clause in SQL databases but with PostgreSQL in particular. Before getting in the details, let’s just explain briefly what exactly are clauses in an SQL database. Clauses Clauses in the SQL are keywords that have definite meaning (similar to their English language counterpart) … Continued

PostgreSQL SMALLINT vs INT

Introduction There are several integer types supported by SQL in general such as INT, BIGINT, SMALLINT and TINYINT. But in this article we discuss SMALLINT vs INT and see how they are different from each other and which one is more appropriate depending on the situation. So let’s begin! SMALLINT vs INT SMALLINT and INT … Continued

PostgreSQL date vs timestamp

Introduction In this article we will explain the difference between PostgreSQL date vs timestamp and when each data type should be utilized. Let’s jump right in! PostgreSQL DATE In order to store date values in database, you have to use data type named as DATE in PostgreSQL. DATE has 4 bytes and it uses those … Continued

INT vs BIGINT

Introduction There are several integer types supported by SQL in general such as INT, BIGINT, SMALLINT and TINYINT. But today we’ll discuss INT vs BIGINT and see how they are different from each other. So let’s begin! INT and BIGINT are both integer numeric data types. Let us compare both of them in terms of … Continued

SQL Select Count

Introduction In this article, we will be discussing the COUNT function in SQL. Before getting in the details, let’s just explain briefly what exactly are functions in an SQL database. Functions Functions in SQL are used to perform certain operations on the result returned from the SELECT statement. Functions are performed on some attribute values. … Continued

Alter Table Add Constraint – How to Use Constraints SQL

Introduction When working with databases you’ll need to manage the data in the database by defining the state of the specific data in a given column. There are several constraint put in data when using PostgreSQL. They include the PRIMARY KEY constraints, FOREIGN KEY constraint, CHECK constraint, UNIQUE constraint and the NOT NULL constraint. Some … Continued

Keep in the know!

Subscribe to our emails and we’ll let you know what’s going on at ObjectRocket. We hate spam and make it easy to unsubscribe.