Loading topic
SUBSTR, the Oracle function that cuts a piece out of a string by position. It assumes you can write basic SELECT statements with a WHERE clause, know VARCHAR2 and string literals, have used the DUAL table, and know that NULL means "no value" in SQL. Earlier chapters c6 min readINSTR, the Oracle function that tells you where one piece of text begins inside another. It assumes you can write a basic SELECT with a WHERE clause, know VARCHAR2 and string literals, and know that DUAL is a one-row table for testing expressions. It a6 min readREPLACE swaps every occurrence of one piece of text for another. If you leave out the replacement, it deletes the matches instead. This chapter assumes you can write a basic SELECT with a WHERE clause, you know VARCHAR2 and string literals, and you know that DUAL is Oracle's one-row helper5 min readSUBSTR and INSTR treat a negative position. It assumes you can write a basic SELECT with a WHERE clause and know VARCHAR2, string literals, the DUAL table and the idea of NULL. It also assumes you have used SUBSTR(string, start, length) with positive positions5 min readSUBSTR(string, start, length) and INSTR(string, search, start, occurrence) behave on their own, inc5 min readREPLACE(string, search, replacement) call works, including that omitting the replacement removes the match. It also assumes you are comfortable with SELECT ... FROM dual and with the fact that Oracle treats an empty string as NULL. Here you will learn h6 min readSELECT with WHERE, you know that dual is a one-row table for testing expressions, and you have used SUBSTR, INSTR, and REPLACE on ordinary input. Here you will learn what each function returns when the input is unusual.6 min readSUBSTR, INSTR, and REPLACE from the earlier chapters, including 1-based positions, the 0 that INSTR returns for no match, and how an empty string behaves as NULL in Oracle. It also assumes you can read a simple pattern such as [0-9]+. The goal is to help y6 min readSUBSTR, INSTR, and REPLACE with positive and negative positions, and that you know the edge cases from earlier chapters. It also assumes you have a basic idea of what a character set is. Every position you have used so far was a count of characters. This chapter c5 min read