Oracle : Difference between SUBSTR and INSTR

SUBSTR returns a specified portion of a string eg SUBSTR('BCDEF',4)
output BCDE

INSTR provides character position in which a pattern is found in a string.

eg INSTR('ABC-DC-F','-',2) output 7 (2nd occurence of '-')

No comments:

Post a Comment