Problem
Table Name: XXEBIZ
SCODE
----------------
'EBIZU'
'EBIZD'
'EBIZT'
'MIN'
'FRE'
For the rows starting with EBIZ Want the result to be displayed as 'EBIZ' instead of its actual value. For the other records for other no need to change in displaying values
REQUIRED OUTPUT:
SCODE
----------------
'EBIZ'
'EBIZ'
'EBIZ'
'MIN'
'FRE'
select decode(substr(scode,1,2), 'EBIZ', 'EBIZ', str_code) from XXEBIZ;
Table Name: XXEBIZ
SCODE
----------------
'EBIZU'
'EBIZD'
'EBIZT'
'MIN'
'FRE'
For the rows starting with EBIZ Want the result to be displayed as 'EBIZ' instead of its actual value. For the other records for other no need to change in displaying values
REQUIRED OUTPUT:
SCODE
----------------
'EBIZ'
'EBIZ'
'EBIZ'
'MIN'
'FRE'
select decode(substr(scode,1,2), 'EBIZ', 'EBIZ', str_code) from XXEBIZ;