I've a table and in that customer name column have some records. I need output as below
Table:
-------
Cname Cno
------ ---
Ramesh babu 1
james k bold 2
Raghu manipati 3
uppu sukanya 4
Expected Output
cname:
------
babu
bold
manipati
sukanya
You need a combination of
SUBSTR()
andINSTR()
.Search for the position of space from last and extract all the characters after that.
SUBSTR(CNAME , INSTR(CNAME,' ',-1) + 1)