×

Language Selection

Basic SQL queries explained in an easy way

SQL Created on March 24, 2025
Project Meeting

1. Create Database

Creates a new database.

sql
CREATE DATABASE mydatabase;

2. Use Database

Selects the database for operations.

sql
USE mydatabase;

3. Create Table

Creates a new table with columns.

sql
CREATE TABLE students (id INT PRIMARY KEY, name VARCHAR(50));

4. Insert Data

Adds a new record to the table.

sql
INSERT INTO students (id, name) VALUES (1, 'Rajesh');

5. Select Data

Fetches all data from a table.

sql
SELECT * FROM students;

6. Filter Data

Fetches data based on conditions.

sql
SELECT * FROM students WHERE id = 1;

7. Update Data

Modifies existing data in a table.

sql
UPDATE students SET name = 'Rahul' WHERE id = 1;

8. Delete Data

Removes data from a table.

sql
DELETE FROM students WHERE id = 1;

9. Order Data

Sorts data in ascending or descending order.

sql
SELECT * FROM students ORDER BY name ASC;

10. Count Rows

Counts total rows in a table.

sql
SELECT COUNT(*) FROM students;

11. Unique Values

Fetches distinct values from a column.

sql
SELECT DISTINCT name FROM students;

12. Limit Results

Fetches limited rows from a table.

sql
SELECT * FROM students LIMIT 2;

13. Join Tables

Combines data from two tables.

sql
SELECT students.name, marks.marks FROM students JOIN marks ON students.id = marks.student_id;

14. Group Data

Groups rows by a column.

sql
SELECT name, COUNT(*) FROM students GROUP BY name;

15. Check NULL

Finds rows with missing values.

sql
SELECT * FROM students WHERE name IS NULL;

Related Notes

India Holidays 2025

  • January
    • January 1 (Wednesday) - New Year's Day
    • January 6 (Monday) - Guru Gobind Singh Jayanti
    • January 14 (Tuesday) - Pongal, Makar Sankranti, Hazarat Ali’s Birthday
    • January 26 (Sunday) - Republic Day
  • February
    • February 2 (Sunday) - Vasant Panchami
    • February 12 (Wednesday) - Guru Ravidas Jayanti
    • February 19 (Wednesday) - Shivaji Jayanti
    • February 26 (Wednesday) - Maha Shivaratri
  • March
    • March 13 (Thursday) - Holika Dahan
    • March 14 (Friday) - Holi, Dolyatra
    • March 28 (Friday) - Jamat Ul-Vida
    • March 30 (Sunday) - Chaitra Sukhladi, Ugadi, Gudi Padwa
    • March 31 (Monday) - Ramzan Id/Eid-ul-Fitr
  • April
    • April 6 (Sunday) - Rama Navami
    • April 10 (Thursday) - Mahavir Jayanti
    • April 18 (Friday) - Good Friday
  • May
    • May 12 (Monday) - Buddha Purnima
  • June
    • June 7 (Saturday) - Bakrid/Eid ul-Adha
  • July
    • July 6 (Sunday) - Muharram/Ashura
  • August
    • August 9 (Saturday) - Raksha Bandhan
    • August 15 (Friday) - Independence Day, Janmashtami, Parsi New Year
    • August 16 (Saturday) - Janmashtami
    • August 27 (Wednesday) - Ganesh Chaturthi
  • September
    • September 5 (Friday) - Milad un-Nabi/Id-e-Milad, Onam
    • September 29 (Monday) - Maha Saptami
    • September 30 (Tuesday) - Maha Ashtami
  • October
    • October 1 (Wednesday) - Maha Navami
    • October 2 (Thursday) - Mahatma Gandhi Jayanti, Dussehra
    • October 7 (Tuesday) - Maharishi Valmiki Jayanti
    • October 10 (Friday) - Karva Chauth
    • October 20 (Monday) - Naraka Chaturdasi, Diwali
    • October 22 (Wednesday) - Govardhan Puja
    • October 23 (Thursday) - Bhai Duj
  • November
    • November 5 (Wednesday) - Guru Nanak Jayanti
    • November 24 (Monday) - Guru Tegh Bahadur’s Martyrdom Day
  • December
    • December 24 (Wednesday) - Christmas Eve
    • December 25 (Thursday) - Christmas

get update from anywhere

Bearing Void gathering light light his eavening unto dont afraid.