SQL 포매터

방언별 옵션으로 SQL 쿼리를 포맷하고 강조 표시

방언
키워드
들여쓰기
스타일
AND/OR
입력
출력
포맷된 SQL이 여기에 표시됩니다...

예시

TypeSQL적용
SELECTSELECT u.id,u.name,u.email,o.total FROM users u INNER JOIN orders o ON o.user_id=u.id WHERE u.active=1 AND o.total>100 ORDER BY o.total DESC LIMIT 20
GROUP BYselect department,count(*) as headcount,avg(salary) as avg_salary from employees where hire_date>'2020-01-01' group by department having count(*)>5 order by avg_salary desc
INSERTINSERT INTO products(name,price,category_id,in_stock) VALUES('Widget',9.99,3,true),('Gadget',24.99,3,false)
UPDATEUPDATE orders SET status='shipped',shipped_at=NOW(),tracking_number='TRK123' WHERE id=42 AND status='pending'
SubquerySELECT name,salary FROM employees WHERE salary>(SELECT AVG(salary) FROM employees WHERE department='Engineering')
CTEWITH monthly_sales AS(SELECT DATE_TRUNC('month',created_at) AS month,SUM(amount) AS total FROM sales GROUP BY 1) SELECT month,total,LAG(total) OVER(ORDER BY month) AS prev_total FROM monthly_sales
© 2026 Developer Toolbox. 모든 권리 보유. 정보