Link to home
Start Free TrialLog in
Avatar of RUA Volunteer2?
RUA Volunteer2?Flag for United States of America

asked on

Working with multiple Parameters in Crystal Reports 8.5

When you are working with multiple parameters that have the option for ALL vs a range of values or individual (discrete) value.

How do you know which parameter to line up or select first. Is there a hierarchy that should be used based on linked tables and do you have to consider that when selecting which parameter should be selected first.

Currently there is a history table {OELINHST_Terr} see image and it will point to the table which I have to get records from the {IMITMIDX_SQL} in Prod_cat field.
Is there a method to this.....?
SOLUTION
Avatar of Mike McCracken
Mike McCracken

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of RUA Volunteer2?

ASKER

I guess the point was does it matter which one I pick based on the primary tables vs the child tables coming from the Table Schema. I have a History table as the primary and a SQL query table that comes off it with a left outer join. I was wondering if it mattered or do you design the RECORD SELECTION to reflect that choice. I was not clear on that in the initial question. Like do I have to use Parenthesis in a certain order or something.....?
MacolaTables.png
For Instance I have all the Parameters to contend with in the RECORD SELECTION.

({Rpt_OELINHST_Terr.inv_dt} in {Rpt_ReportingDates.CurrFromDateYTD} to {Rpt_ReportingDates.CurrToDateYTD} or
{Rpt_OELINHST_Terr.inv_dt} in {Rpt_ReportingDates.PriorFromDateYTD} to {Rpt_ReportingDates.PriorToDateYTD}) and
{Rpt_OELINHST_Terr.item_no} in {?ItemRange} and
{Rpt_OELINHST_Terr.cus_no} in {?CustomerRange} and
if {?RptTerr} = "ALL" and {?AdoptedTerr} = "ALL" then
{Rpt_OELINHST_Terr.Terr} in "99" to "ZZ"
else
    if {?RptTerr} = "ALL" and {?AdoptedTerr} <> "ALL" then
    ({Rpt_OELINHST_Terr.Terr} in "99" to "ZZ" and {@TimsTerritory} )
       or ({Rpt_OELINHST_Terr.Terr} in {?AdoptedTerr} and {@AdoptedTerritory} and {ARCUSFIL_SQL.terr} in "99" to "ZZ")
    else
        if {?RptTerr} <> "ALL" and {?AdoptedTerr} = "ALL" then
        ({Rpt_OELINHST_Terr.Terr} in {?RptTerr} and {@TimsTerritory})
          or ({Rpt_OELINHST_Terr.Terr} in "99" to "ZZ" and {@AdoptedTerritory} and {ARCUSFIL_SQL.terr} in {?RptTerr})
        else
        ({Rpt_OELINHST_Terr.Terr} in {?RptTerr} and {@TimsTerritory} )
          or ({Rpt_OELINHST_Terr.Terr} in {?AdoptedTerr} and {@AdoptedTerritory} and {ARCUSFIL_SQL.terr} in {?RptTerr} )
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
That worked thank you.