개인적인 정리

[Oracle] LTRIM() 본문

DB/ORACLE

[Oracle] LTRIM()

yeon.Biju 2020. 4. 8. 22:11

오라클 LTRIM()

 

LTRIM()

   -

 

LTRIM(char)

LTRIM(char, set)

의 형태

 

LTRIM removes from the left end of char all of the characters contained in set. If you do not specify set, then it defaults to a single blnak. If char is a character literal, then you must enclose it in single quotation marks. Oracle Database begins scanning char from its first character and removes all characters that apper in set until reaching a character not in set and then returns the result.

 

Both char and set can be any of the data types CHAR, VARCHAR2, NCHAR, NVARCHAR2, CLOB, or NCLOB. The string returned is of VARCHAR2 data type if char is a character data type, NVARCHAR2 if char is a national data type, and a LOB if char is a LOB data type.

 

SQL>SELECT LTRIM('   abcdefgabcdefg') FROM DUAL ;

   --> abcdefgabcdefg

 

SQL> SELECT LTRIM('abcdefgabcdefg', 'abcde') FROM DUAL ;

   --> fgabcdefg

'DB > ORACLE' 카테고리의 다른 글

[Oracle] MOD()  (0) 2020.04.09
[Oracle] MIN()  (0) 2020.04.09
[Oracle] MEDIAN()  (0) 2020.04.09
[Oracle] MAX()  (0) 2020.04.09
[Oracle] LPAD()  (0) 2020.04.08
[Oracle] LOWER()  (0) 2020.04.08
[Oracle] LOG()  (0) 2020.04.08
Oracle LOCALTIMESTAMP()  (0) 2020.04.08
Comments