Skip to Content
avatar image
Former Member

Displaying records based on a condition

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

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Sep 02, 2008 at 06:12 AM

    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

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 01, 2008 at 08:20 AM

    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

    Add comment
    10|10000 characters needed characters exceeded

  • Sep 02, 2008 at 09:46 PM

    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

    Add comment
    10|10000 characters needed characters exceeded