## Creating a parameter

To create a parameter in a catalog, follow the steps below:

1. In JReport Designer, open the catalog file in which you want to create the parameter.
2. In the Data tab of the Catalog Browser, expand the data source that will include the parameter, right-click the Parameters node, and then select Add Parameter to bring up the Create Parameter dialog. See the dialog.

3. In the Parameter Name field, input a name for the parameter.
4. Select a parameter type from the Value Setting drop-down list.
5. In the values section, specify the parameter values as required. The section varies with the type you select from the Value Setting drop-down list.
   - For Type-in Parameter:
     1. Specify the data type of the parameter value from the Value Type drop-down list.
     2. Click to add a value line, double-click in it and then type in a value of the specified data type.
     3. Repeat the first step to add more values.

        To adjust the order of the values, click or ; to remove any unwanted value, select it in the list and then click .

     4. Specify the value which will be set as the default selected value in the Enter Parameter Value dialog by selecting it from the list.

   - For Bind with Single Column:
     1. Select a field from the Bind Column drop-down list. This field is used to filter the query when running a report with the parameter.
     2. If you want the values of another field to be displayed in the Enter Parameter Values dialog, which makes more sense to report end users than the values of the Bind Column field, select that field from the Display Column drop-down list.
   - For Bind with Cascading Columns:
     1. Select a table from the Data Source drop-down list. All fields in the table will be available for value selection.
     2. Click to add a parameter row.
     3. Click in the Bind Column cell and select a field from the drop-down list.
     4. If you want the values of another field to be displayed in the Enter Parameter Values dialog, which makes more sense to report end users than the values of the Bind Column field, click in the Display Column cell and then select that field from the drop-down list.
     5. Click in the Parameter cell to create the parameter. A name for the parameter will then be automatically added by JReport.
     6. Repeat step 2 to 4 to create more parameters. Make sure that the selected Bind Column fields are of cascading relationship one level by one level down. In this way a group of cascading parameters will be created.

        To adjust the order of the parameters, click or ; to remove any unwanted parameter from the cascading group, select it and then click .

6. In the Options box, set options for the parameter according to your requirement.
7. When done, click OK to create the parameter.