Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Dollar sign notation

Peter GjelstrupNov 3 2010 — edited Nov 3 2010
Hi members,

I just came across some PL/SQL package using some notation which I have never seen before, nor can find in PL/SQL reference. It is use of $ (In a conditional statement)

Here's an example:
SQL> create or replace procedure p as
begin
  $if 1 = 1 $then
     dbms_output.put_line ('Why can we use dollar sign?');
     dbms_output.put_line ('And no END IF??');
  $end
end p;
Procedure created.
SQL> show errors
No errors.
SQL> exec p
Why can we use dollar sign?
And no END IF??
PL/SQL procedure successfully completed.
SQL> show release
release 10.2.0.3.0
Just wondered what that really is, and why would one wanna do that? - Is it some old style Pl/SQL, or?

P.S: Package was written in 1997


Best regards
Peter
This post has been answered by Saubhik Banerjee on Nov 3 2010
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 1 2010
Added on Nov 3 2010
2 comments
1,302 views