Online SQL Compiler
Write, test, and execute SQL queries online. Practice SQL with sample databases, experiment with different queries, and learn database concepts in an interactive environment.
Database Schema
📋 employees
idINTEGER 🔑
first_nameTEXT
last_nameTEXT
emailTEXT
departmentTEXT
salaryINTEGER
hire_dateDATE
8 rows
📋 departments
idINTEGER 🔑
nameTEXT
budgetINTEGER
manager_idINTEGER
4 rows
📋 projects
idINTEGER 🔑
nameTEXT
start_dateDATE
end_dateDATE
budgetINTEGER
department_idINTEGER
4 rows
Sample Queries
SQL Editor
Lines: 11 | Characters: 233
Tip: Use semicolon (;) to separate multiple queries
SQL Reference
Basic Queries:
- •
SELECT * FROM table_name;
- •
SELECT col1, col2 FROM table_name;
- •
WHERE condition
- •
ORDER BY column ASC/DESC
- •
GROUP BY column
- •
HAVING condition
Functions & Operators:
- •
COUNT(), SUM(), AVG(), MIN(), MAX()
- •
=, !=, <, >, <=, >=
- •
AND, OR, NOT
- •
LIKE, IN, BETWEEN
- •
IS NULL, IS NOT NULL
Note: This is a demo SQL compiler running client-side with sample data. Advanced SQL features and real database connections are not available. Perfect for learning and testing basic SQL queries!