Sunday, 17 September 2017

Trim Function

TRIM heading  or trailing  characters or both from the character string.
LEADING trim the leading characters.
TRAILING trim trailing  characters.
BOTH OR trim both leading or trailing  characters.

Syntax: TRIM(CHAR,SET)
Example:

Use of LTRIM Function
SELECT 'xyzXxyORACLE' OrgStr,LTRIM('xyzXxyORACLE', 'xzyX') Ltrim FROM DUAL;
SELECT LTRIM(' Oracle') FROM DUAL;  --trimming space



No comments:

Post a Comment