
Now for starters, SQL is a set language. PL/SQL, on the other hand, is a procedural language. When you write an anonymous block of PL/SQL, you can include the optional DECLARE keyword to start the DECLARE section. Procedures and functions also have this section, but they do not use the DECLARE keyword. This section starts after the IS or AS keyword.
In PL/SQL, the inclusion of NULL in your expression often turns the whole result NULL. However there are some exceptions. If you concatenate a character string with NULL, the NULL acts like an empty string and leaves the character string unchanged.
Normally I use a NUMBER variable type. I was enlightened when I found out that the optional precision for this type is the total number of significant digits in the value. It is not the total digits, as you can have huge numbers with more effective digits than are allowed for the precision. I also have discovered that the BINARY_INTEGER TYPE, which is equivalent to PLS_INTEGER, is much more efficient than NUMBER.