cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying records based on a condition

Former Member
0 Kudos

I have a table called payments which contains information related to payments made to a customer. The payments table has a field called payment type. I want to select payments of three different types. Lets call them type1, type2 and type3. I can select records of this type using the record filter.

In the report I am printing payments of the three types

Type 1 payment: Amount of type1 from the payments table

Type 2 payment: Amount of type2 from the payments table

Type 3 payment: Amount of type3 from the payments table

How do I select the appropriate record to match the kind of payment that I need to print in a specific spot on the report? Any help would be greatly appreciated?

Regards

Moiz

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

You can define parameters to display records based on particular condition.

define parameters of dynamic type accoring to your condtion.

Insert parameters into report and the select expert record define the condtion on defined parameters.

Hope this will help you.

Thanks,

Neetu

Answers (2)

Answers (2)

former_member230846
Contributor
0 Kudos

Hi Moiz,

I may need more clarification on what you want in your report, but from the information provided, you should be able to create a parameter field from the "Field Explorer" (View|Field Explorer). Once you have created the parameter field, go to Report|Selection Formulas|Record... In here you can create a selection formula. For example,

if {?your.parameter} = "All" then true

else

{paytype.field} = {?your.parameter}

Basically, the above selection formula will display all 3 payment types if you enter the value All when prompted, otherwise it will display the records you selected for the parameter value.

If this is not what you're looking for, please reply and add additional information for clarity.

Regards,

Wallie

Former Member
0 Kudos

Hello Moiz,

several ways how to select record are described in the [Crystal Reports 2008 User's Guide|http://help.sap.com/businessobject/product_guides/cr2008/en/xir3_cr_usergde_en.pdf]

chapter 9 beginning at page 213.

Best regards

Falk