일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 31 |
- Sring Functions and Operators
- String Functions and Operators
- 전자정부표준프레임워크
- Tibero
- Date and Time Function
- HTTP
- SVN
- Date and Time Functions
- 전자정부 표준프레임워크
- String Functions and Date Operators
- MySQL
- Oracle
- 방화벽
- String Function and Operators
- 오라클
- 티베로
- Data and Time Functions
- 윈도우
- Today
- Total
목록MySQL (149)
웹이야기
MySQL 문자열 함수와 연산자 OCTET_LENGTH() - OCTET_LENGTH(str) 의 형태 OCTET_LENGTH() is a synonym for LENGTH().
MySQL 문자열 함수와 연산자 OCT() - OCT(N) 의 형태 Returns a string representation of the octal value of N. where N is a longlong(BIGINT) number. This is equivalent to CONV(N, 10, 8). Returns NULL if N is NULL. mysql> SELECT OCT(12); +---------+ | OCT(12) | +---------+ | 14 | +---------+ 1 row in set (0.00 sec)
MySQL 문자열 함수와 연산자 MID() - MID(str, pos, len) 의 형태 MID(str, pos, len) is a synonym for SUBSTRING(str, pos, len).
MySQL 문자열 함수와 연산자 MAKE_SET() - MAKE_SET(bits, str1, str2, ...) 의 형태 Returns a set value(a string containing substrings separated by , characters) consisting of the strings that have the corresponding bit in bits set. str1 correspondes to bit 0, str2 to bit 1, and so on. NULL values in str1, str2, ... are not appended to the result. mysql> SELECT MAKE_SET(1, 'a', 'b', 'c') ; +--------------------..
MySQL 문자열 함수와 연산자 LTRIM() - LTRIM(str) 의 형태 Returns the string str with leading space characters removed. This function is multibyte safe. mysql> SELECT LTRIM(' aaaa'); +-------------------+ | LTRIM(' aaaa') | +-------------------+ | aaaa | +-------------------+ 1 row in set (0.00 sec)
MySQL 문자열 함수와 연산자 LPAD() - LPAD(str, len, padstr) 의 형태 Returns the string str, left-padded with the string padstr to a length of len characters. If str is longer than len, the return value is shortened to len characters. mysql> SELECT LPAD('hi', 4, '??') ; +---------------------+ | LPAD('hi', 4, '??') | +---------------------+ | ??hi | +---------------------+ 1 row in set (0.00 sec) mysql> SELEC..
MySQL 문자열 함수와 연산자 LOWER() - LOWER(str) 의 형태 Returns the string str with all characters changed to lowercase according to the current character set mapping. The default is utf8mb4. (MySQL 8. x 버전 이상부터 일 것이다.) mysql> SELECT LOWER('ABCD') ; +---------------+ | LOWER('ABCD') | +---------------+ | abcd | +---------------+ 1 row in set (0.00 sec) LOWER() (and UPPER()) are ineffective when applied to b..
MySQL 문자열 함수와 연산자 LOCATE() - LOCATE(substr, str) LOCATE(substr, str, pos) 의 형태 The first syntax returns the position of the first occurence of substring substr in string str. The second syntax returns the position of the first occurence of substring substr in string str, starting at position pos. Returns 0 if substr is not in str. Returns NULL if any argument is NULL. mysql> SELECT LOCATE('bar',..
MySQL 문자열 함수와 연산자 LOAD_FILE() - LOAD_FILE(file_name) 의 형태 Reads the file and returns the file contents as a string. To use this function, the file must be located on the server host, you must specify the full path name to the file, and you must have the FILE privilege. The file must be readable by the server and its size less than max_allowed_packet bytes. If the secure_file_priv system variable..
MySQL 문자열 함수와 연산자 LEFT() - LEFT(str, len) 의 형태 Returns the leftmost len characters from the string str, or NULL if any argument is NULL. mysql> SELECT LEFT ('foobarbar', 5) ; +-----------------------+ | LEFT ('foobarbar', 5) | +-----------------------+ | fooba | +-----------------------+ 1 row in set (0.00 sec) mysql> SELECT LEFT ('foo', 5) ; +-----------------+ | LEFT ('foo', 5) | +------------..
MySQL 문자열 함수와 연산자 LCASE() - LCASE(str) 의 형태 LCASE() is a synonym for LOWER(). LCASE() used in a view is rewritten as LOWER() when storing the view's defination. (Bug #12844279)
MySQL 문자열 함수와 연산자 INSTR() - INSTR(str, substr) 의 형태 Returns the position of the first occurence of sustring substr in string str. This is the same as the two-argument form of LOCATE(), except that the order of the arguments is reversed. This function is multibyte safe, and is case-sensitive only if at least one argument is a binary string. mysql> SELECT INSTR('foobarbar', 'bar') ; +-------------..
MySQL 문자열 함수와 연산자 INSERT() - INSERT(str, pos, len, newstr) 의 형태 Returns the string str, with the substring beginning at position pos and len characters long replaced by the string newstr. Returns the original string if pos is not within the length of the string Replaces the rest of the string from position pos if len is not within the length of the rest of the string. Returns NULL if any argumen..
MySQL 문자열 함수와 연산자 HEX() - HEX(str) HEX(N) 의 형태 For a string argument str, HEX() returns a hexadecimal string representation of str where each byte of each character in str is converted to two hexadecimal digits. (Multibyte characters therefore become more than two digits.) The inverse of this operation is performed by UNHEX() function. For a numeric argument N, HEX() returns a hdxadecimal string..
MySQL 문자열 함수와 연산자 FROM_BASE64() - FROM_BASE64(str) 의 형태 Takes a string encoded with the base-64 encoded rules used by TO_BASE64() and returns the decoded result as a binary string. The result is NULL if the argument is NULL or not a valid base-64 string. mysql> SELECT TO_BASE64('abc'), FROM_BASE64(TO_BASE64('abc')) ; +------------------+-------------------------------+ | TO_BASE64('abc') | FROM_..
MySQL 문자열 함수와 연산자 FORMAT() - FORMAT(X, D [,locale]) 의 형태 Formats the number X to a format like '#, ###,###.##', rounds to D decimal places, and returns the result as a string. If D is 0, the result has no decimal point or fractional part. The optional third parameter enables a locale to be specified to be used for the result number's decimal point, thousands separator, and grouping between separ..
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 arithmet..
MySQL 문자열 함수와 연산자 FIELD() - FIELD(str, str1, str2, str3, ...) 의 형태 Returns the index (position) of str in the str1, str2, str3, ... list. Returns 0 if str is not found. If all arguments to FIELD() are strings, all arguments are compared as strings. If all arguments are numbers, they are compared as numbers. Otherwise , the arguments are compared as double. If str is NULL, the return value is 0 b..
MySQL 문자열 함수와 연산자 EXPORT_SET() - 이건 뭔가 싶다. EXPORT_SET(bits, on, off[, sperator[,number_of_bits]]) 의 형태 Return a string such that for every bit set in the value bits, you get an on string and for every bit not set in the value, you get an off string. Bits in bits are examined from right to left(from low-order to high-order bits). Strings are added to the result from left to right, separated by th..
MySQL 문자열 함수와 연산자 ELT() - ELT(N, str1, str2, str3....) 의 형태 ELT() returns the N th element of the list strings: str1 if N=1, str2 if N=2, and so on. Retruns NULL if N is less than 1 or greater than the number of arguments. ELT() is the complement of FIELD(). mysql> SELECT ELT(1, 'A', 'B', 'C'); +-----------------------+ | ELT(1, 'A', 'B', 'C') | +-----------------------+ | A | +-----------------..