Variable Grouping

Cory Fifield -

Trouble viewing images? Click on images to enlarge.

Important - This guide was done using the Northwinds sample database.

 

 

 

1. On the Parameters tab, click Add Parameter.

mceclip0.png

 

2. Set the Datatype, Description, Name and Type for the new parameter. Set the Type property to Combobox. (Note: String should be used most of the time for Datatype.)

mceclip1.png

 

3. Click on the Values List and enter the values that will be used for the variable grouping (EmployeeID, OrderDate, City) then click OK.

mceclip2.png

 

4. Open Finished Reports and Right Click on the Details field list and select Add Calculated Field.

mceclip3.png

 

5. Right Click on the New Expression and select Edit Expression.

mceclip4.png

 

6. Enter the code for your expression. For every additional variable in the expression, you will use Iif( , ,)

The format for creating the different variables is indicated below:

 

 Iif( [parameter] = 'one' , field_one , Iif( [parameter] = 'two' , field_two , 'else' ))

 

mceclip6.png

 

7. Under Group and Sort click Add a Group and group using the new expression.

mceclip7.png

 

8. Save the Finished Report, then go back to the VDM main screen and add a filter for OrderDate is Less than or equal to 10/31/1996. (This will return less data making it easier to see the results)

 

9. Search the View and enter the parameters, then go to Finished Reports

 

Variable Grouping Preview (EmployeeID)

mceclip11.png

 

 

Variable Grouping Preview (OrderDate)

mceclip10.png

 

 

Variable Grouping Preview (City)

mceclip12.png

Have more questions? Submit a request

Comments

  • Avatar
    Nathanial Wcislak

    I think this may need an update, there is no longer an option to right click parameters on the finished reports designer.