I am new at oracle and working on a small project. I am trying to find "[" in a field and produce from that point to the end of the field.
My code is as follows:
declare
startPos PLS_Integer;
endPos PLS_Integer;
begin
set startPos := (Select top 1(instr(description, '[', 1, 1)-1) FROM INSTRTEST);
dbms_output.put_line(startPos);
end;
The error I am receiving:
ORA-06550: line 5, column 5:
PL/SQL: ORA-00922: missing or invalid option
ORA-06550: line 5, column 1:
PL/SQL: SQL Statement ignored
3. endPos PLS_Integer;
4. begin
5. set startPos := (Select top 1(instr(description, '[', 1, 1)-1) FROM INSTRTEST);
6. --endPos := (select len(description)FROM INSTRTEST)
7. dbms_output.put_line(startPos);
Thanks in advance for any help available.
culbysl