I have a few select statements, they all need to use the same variable. So can I define a variable first, then use it directly in the following statement, like this:
declare variable; -- a to_date function
select statement 1;
select statement 2;
select statement 3;
...
So when the conditions change, I can just modify the variables. How can I accomplish it use pl-sql(or sql-plus) in oracle?