Ampersand Substitution

The Ampersand (&) and Double-Ampersand (&&) are used in oracle as prompts for input

A way to give the end user a little bit of control when dealing with dynamic queries user input.

The ampersand (&) is used as a substitution character to prompt users for values during script execution.


SELECT * FROM employees WHERE department_id = &dept_id;

Modifying Prompts

To modify promt, you may add code like this at the begiinging of the code:

Makie sure that the ACCEPT AND PROMPT are on the same line.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top