SQL Operator📦 Database/SQL2023. 4. 9. 10:16
Table of Contents
💡 Operator
SQL에는 다양한 연산자가 있다.
산술연산자, 비트연산자, 비교연산자, 논리연산자등 대부분 프로그래밍의 연산자와 비슷하다.
Operator | Description | Example |
---|---|---|
+ | Add | Try it |
- | Subtract | Try it |
* | Multiply | Try it |
/ | Divide | Try it |
% | Modulo | Try it |
SQL 비트 연산자
Operator | Description |
---|---|
& | Bitwise AND |
| | Bitwise OR |
^ | Bitwise exclusive OR |
SQL 비교 연산자
Operator | Description | Example |
---|---|---|
= | Equal to | Try it |
> | Greater than | Try it |
< | Less than | Try it |
>= | Greater than or equal to | Try it |
<= | Less than or equal to | Try it |
<> | Not equal to | Try it |
SQL 복합 연산자
Operator | Description |
---|---|
+= | Add equals |
-= | Subtract equals |
*= | Multiply equals |
/= | Divide equals |
%= | Modulo equals |
&= | Bitwise AND equals |
^-= | Bitwise exclusive equals |
|*= | Bitwise OR equals |
SQL 논리 연산자
Operator | Description | Example |
---|---|---|
ALL | TRUE if all of the subquery values meet the condition | Try it |
AND | TRUE if all the conditions separated by AND is TRUE | Try it |
ANY | TRUE if any of the subquery values meet the condition | Try it |
BETWEEN | TRUE if the operand is within the range of comparisons | Try it |
EXISTS | TRUE if the subquery returns one or more records | Try it |
IN | TRUE if the operand is equal to one of a list of expressions | Try it |
LIKE | TRUE if the operand matches a pattern | Try it |
NOT | Displays a record if the condition(s) is NOT TRUE | Try it |
OR | TRUE if any of the conditions separated by OR is TRUE | Try it |
SOME | TRUE if any of the subquery values meet the condition |
'📦 Database > SQL' 카테고리의 다른 글
SQL DateDiff (0) | 2023.05.22 |
---|---|
SQL Stored Procedure (0) | 2023.04.09 |
SQL Null Function (0) | 2023.04.09 |
SQL Case (0) | 2023.04.09 |
SQL Select Into & Insert Into Select (0) | 2023.04.09 |
@신건우 :: 우주먼지
열심히 살고 싶은 사람의 메모장
포스팅이 좋았다면 "좋아요❤️" 또는 "구독👍🏻" 해주세요!