LEFT - RIGHT
suggest changeLEFT and RIGHT are not standard SQL. SQL Server accepts them. Oracle does not; use SUBSTR and LENGTH there.
SELECT LEFT('Hello', 2) -- returns He
SELECT RIGHT('Hello', 2) -- returns lo
SELECT SUBSTR('Hello', 1, 2) -- returns He
SELECT SUBSTR('Hello', LENGTH('Hello') - 2 + 1, 2) -- returns lo
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents