If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Detail Filter Expression

Started by ssmith001, 23 Aug 2018 06:42:58 PM

Previous topic - Next topic

ssmith001

Looking for some assistance with a detail filter expression, that is not working and returning the correct results. I've commented out various sections which appear to work, but when I uncomment the entire expression, something is wrong and it's giving me back odd results.

Here's the matrix that I'm working off of...

Runsheet Type           FRM_PNT_TYP_ENU            TO_PNT_TYP_ENU     

Allocated                          3                                             4

Shuttle                             3                                             3                  FRM_STA_CD  =  TO_STA_CD

Linehaul                           3                                             3                  FRM_STA_CD  <>  TO_STA_CD

Allocated & Shuttle            3                                           3 or 4             FRM_STA_CD   =  TO_STA_CD

Allocated & Linehaul           3                                          3 or 4              FRM_STA_CD  <>  TO_STA_CD

Shuttle & Linehaul             3                                              3

and here's the expression...


     (?pRunSheetType? = 'Allocated'             AND [FRM_PNT_TYP_ENU] = 3 AND [TO_PNT_TYP_ENU] = 4)
OR (?pRunSheetType? = 'Shuttle'               AND [FRM_PNT_TYP_ENU] = 3 AND [TO_PNT_TYP_ENU] = 3 AND [FRM_STA_CD] = [TO_STA_CD])
OR (?pRunSheetType? = 'Linehaul'              AND [FRM_PNT_TYP_ENU] = 3 AND [TO_PNT_TYP_ENU] = 3 AND [FRM_STA_CD]  <> [TO_STA_CD])
OR (?pRunSheetType? = 'Allocated & Shuttle'   AND [FRM_PNT_TYP_ENU] = 3 AND ([TO_PNT_TYP_ENU] = 3 OR [TO_PNT_TYP_ENU] = 4) AND [FRM_STA_CD] = [TO_STA_CD])
OR (?pRunSheetType? = 'Allocated & Linehaul'  AND [FRM_PNT_TYP_ENU] = 3 AND ([TO_PNT_TYP_ENU] = 3 OR [TO_PNT_TYP_ENU] = 4) AND [FRM_STA_CD]  <> [TO_STA_CD])
OR (?pRunSheetType? = 'Shuttle & Linehaul'    AND [FRM_PNT_TYP_ENU] = 3 AND [TO_PNT_TYP_ENU]  = 3)
OR (?pRunSheetType? = 'All'  AND [FRM_PNT_TYP_ENU] = 3 AND ([TO_PNT_TYP_ENU] = 3 OR [TO_PNT_TYP_ENU] = 4) AND ([FRM_STA_CD]  <> [TO_STA_CD]) OR [FRM_STA_CD]  = [TO_STA_CD])