You can rename a database using ALTER DATABASE statement. Limitations and restrictions of renaming a database 1. Database cannot be renamed to an existing database… [Read More]
SQL Data Types
SQL Data type defines the values that a column can accept, for example if a column of the table has an int data type, then… [Read More]
SQL Tutorial for Beginners: Learn SQL
This SQL tutorial is design for beginners as well as advanced professionals. Each tutorial is started from basic level so a SQL beginner will be… [Read More]
SQL SELECT AVG() Function
SQL AVG() function returns the average of values of a numeric column in a table. AVG() Syntax SELECT AVG(column_name) FROM table_name WHERE condition; SQL AVG()… [Read More]
SQL SELECT SUM() Function
SQL SUM() function returns the total sum of values of a numeric column in a table. SUM() function Syntax SELECT SUM(column_name) FROM table_name WHERE condition;… [Read More]
SQL SELECT MIN, MAX Functions
SQL MIN() & MAX() functions are used to find the lowest value and largest value of a column respectively. MIN(column_name): It returns the lowest value… [Read More]
SQL DELETE Statement
SQL DELETE statement is used to permanently delete existing records (rows) from the table. This statement can be used to delete one or more records… [Read More]
SQL UPDATE Statement
The UPDATE statement in SQL is used to update records in the table. We can modify one or multiple records (rows) in table using UPDATE… [Read More]
SQL NULL Check in Where clause – IS NULL and IS NOT NULL
In SQL Where clause tutorial, we learned how to use comparison operators such as =, <, > etc in where clause for conditions. However when… [Read More]
SQL SELECT AS – Alias in SQL
SQL SELECT AS is used to assign temporary names to table or column name or both. This is known as creating Alias in SQL. In… [Read More]
SQL Select Random Rows from Table
Sometimes there is a need to fetch random record from the table. For example – You have a list of quotes stored in a table… [Read More]
SQL INSERT INTO SELECT Statement
In the previous tutorial, we learned the SQL INSERT INTO statement. In this guide, we will see a useful variation SQL INSERT INTO SELECT statement… [Read More]
SQL INSERT INTO Statement
The SQL INSERT INTO statement is used to add new records (rows) in the table. While adding a record in the table, it is not… [Read More]
SQL – Combining AND, OR and NOT together in where clause
In the last tutorial, we learned how to use logical operators AND, OR and NOT in SQL where clause. In this guide, we will learn… [Read More]
SQL AND, OR and NOT Operators with examples
In the last tutorial, we learned how to use where clause in an SQL statement. In this guide, we will learn about logical operators AND… [Read More]