일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
- String Functions and Date Operators
- Date and Time Functions
- Tibero
- String Function and Operators
- 티베로
- Sring Functions and Operators
- MySQL
- 오라클
- HTTP
- Date and Time Function
- 방화벽
- Data and Time Functions
- SVN
- 전자정부 표준프레임워크
- 전자정부표준프레임워크
- Oracle
- 윈도우
- String Functions and Operators
- Today
- Total
웹이야기
[MySQL] FIND_IN_SET() 본문
MySQL 문자열 함수와 연산자
FIND_IN_SET()
-
FIND_IN_SET(str, strlist)
의 형태
Returns a value in the range of 1 to N if the string str is in the string list strlist consisting of N substrings. A String list is a string composed of substrings separated by , characters. If the first argument is a constant string and the second is a column of type SET, the FIND_IN_SET() function is optimized to use bit arithmetic. Returns 0 if str is not in strlist or if strlist is the empty string. Returns NULL if either argument is NULL. This function does not work properly if the first argument contains a comma(,) character.
mysql> SELECT FIND_IN_SET('C' , 'A,B,B,C,D') ;
+--------------------------------+
| FIND_IN_SET('C' , 'A,B,B,C,D') |
+--------------------------------+
| 4 |
+--------------------------------+
1 row in set (0.00 sec)
'D > MySQL' 카테고리의 다른 글
MySQL FROM_BASE64() (0) | 2020.04.13 |
---|---|
[MySQL] FORMAT() (0) | 2020.04.13 |
[MySQL] FIELD() (0) | 2020.04.08 |
[MySQL] EXPORT_SET() (0) | 2020.04.08 |
[MySQL] ELT() (0) | 2020.04.08 |