Showing posts with label Oracle 10g: Concate Strings. Show all posts
Showing posts with label Oracle 10g: Concate Strings. Show all posts
Saturday, January 19, 2008
Oracle 10g: Concatenation Operator (||)
Careless mistake that causes severe injury...
MSSQL: +
EXAMPLE:
SELECT * FROM GBL_CIVILANT_MST WHERE ICNO LIKE '%' + SEARCHITEM_ + '%'
ORACLE:
EXAMPLE:
SELECT * FROM GBL_CIVILANT_MST WHERE ICNO LIKE '%' SEARCHITEM_ '%'
MSSQL: +
EXAMPLE:
SELECT * FROM GBL_CIVILANT_MST WHERE ICNO LIKE '%' + SEARCHITEM_ + '%'
ORACLE:
EXAMPLE:
SELECT * FROM GBL_CIVILANT_MST WHERE ICNO LIKE '%' SEARCHITEM_ '%'
Oracle 10g: Concatenate(Concat)
SYNTAX:
CONCAT(char1, char2)
PURPOSE:
Returns char1 concatenated with char2. This function is equivalent to the concatenation operator ().
EXAMPLE:
This example uses nesting to concatenate three character strings:
SELECT CONCAT( CONCAT(ename, ' is a '), job) "Job" FROM emp WHERE empno = 7900
Job
-------------------------
JAMES is a CLERK
CONCAT(char1, char2)
PURPOSE:
Returns char1 concatenated with char2. This function is equivalent to the concatenation operator ().
EXAMPLE:
This example uses nesting to concatenate three character strings:
SELECT CONCAT( CONCAT(ename, ' is a '), job) "Job" FROM emp WHERE empno = 7900
Job
-------------------------
JAMES is a CLERK
Subscribe to:
Posts (Atom)