ORDER BY, Comparision Operators

hh_binvely·2024년 3월 6일
0

Part 03. SQL

목록 보기
4/11
post-thumbnail

1. ORDER BY

ORDER BY 문법

- SELECT 문에서 데이터를 특정 컬럼을 기준으로 오름차순 혹은 내림차순 정렬
* ASC(Ascending) : 오름차순 정렬
* DESC(Descending) : 내림차순 정렬
** ASC를 생략해도 기본은 오름차순 정렬

select column1, column2, ...
from tablename
where condition
order by column1 ASC | DESC, column2 ASC | DESC, ... ;

2. Comparision Operators (비교 연산자)

Comparision Operators 문법

select column1, column2, ...
from tablename
<span style='background-color: #fff5b1'>where condition(비교연산자)</span>
order by column1 ASC | DESC, column2 ASC | DESC, ... ;

0개의 댓글

관련 채용 정보