Filtering out Kit components on OrderDtl in BAQ

Having a senior moment …

I’m trying to exclude the kit components from the OrderDtl table in a BAQ. It looks like the only way to tell if a OrderDtl record is for a component of a sales kit, is by comparing the OrderLine and KitParentLine.

If an order line is not a kit component, then OrderLine = KitParentLine

But however I try to add that to my BAQ, it goes from under 2 seconds, to over 30(timesout).

I’ve tried

  • Adding a table criteria

    • OrderDtl.OrderLine = OrderDtl.KitParentLine table field value
  • Adding an extra table relationship

    • OrderDtl.KitParentLine = OrderRel.OrderLine
  • Adding a subquery criteria
    image

Any thoughts?

OrderDtl.KitFlag is blank for non-kit lines, “C” for component lines, and “P” for parent lines.

1 Like

Damn … How’d I miss that?