We have two types of parameters.
User Parameters
is created by the developer so that end user can enter the filter condition
he/she needs. We can use the above example to understand. Under Data Model
you can see User Parameters. So when you want to create a user parameter
highlight the user parameters node and click on create or + sign
on your tool bar. It creates a parameter and names it as P_1. Then dobule
click P_1 parameter and change the name to customer_no. Now we can use
this user parameter in your query.
System Parameters.
If you want to print 2 copies of same report, oracle reports provides
a parameter called copies, we can just type 2 in that parameter field and
it prints 2 copies. Orientation is another system parameter which we use
most often, whether to print your report portrait or landscape. Now you
know the difference between user parameter and system parameters.
Parameter Form
is used to specify the filter options by the user when he/she runs
the report. You can have as many parameters as you want. When ever you
create a new parameter you must specify the data type ( default is number
) and assign the default values , what are all the valid values either
static values or values pulled from a table or tables uning the SQL.
Creating a Parameter Form.
Adding new Parameters.
Viewing Parameter Form.
Once we run the report after putting the values in the parameter form we can build the where clause so that query filters the data.
Lexical Parameters.
where you build the part of sql or whole sql based on the user input.
When you use &parmater_name then the whole string of the variable gets
replaced in the sql.
Triggers associated with Parameter Forms.