So I’m creating a very simple dashboard to add up part weights on a PO. We want to use this for Galvanizing pricing. We have the part weight populated in the Part Entry so I just join PoDetail (for the part number) to PORel (for the qty) and join the Part table to PoDetail (to get the weight). I display a few fields, then make a calculated field where I multiply the RelQuantity time the NetWeight on the Part table.
Run wide open, this obviously hits the 1000 rows max, so to check it, I add a temporary table filter and I get 44 rows, which is right. I take that out, because I’m going to put it into a dashboard with a tracker in it to filter it.
We I get to the dashbaord, I add my query, add my trackers, like normal. But I only get back 14 rows!! what the heck? If I add a criteria back in the BAQ for only open lines, it returns all 44. Take it out, back to 44. If I order my query by PO, I get no rows.
So it seems like my query is timing out, which is odd because the results come back at the snap of a finger. Super fast.
Can anyone tell me why the dashboard is doing this? I don’t want to add that stupid parameter pop up. For right now, I’m just filtering the BAQ to only show open lines, but I don’t want it that way going forward.
Here’s the query phrase if anyone is interested. I added in the PO header in case that makes a difference, but it didn’t seem to. This phrase has the open filters in it which I would like to remove.
select top (1000)
[POHeader].[PONum] as [POHeader_PONum],
[PODetail].[PONUM] as [PODetail_PONUM],
[PODetail].[POLine] as [PODetail_POLine],
[PORel].[PORelNum] as [PORel_PORelNum],
[PODetail].[PartNum] as [PODetail_PartNum],
[PORel].[XRelQty] as [PORel_XRelQty],
(PORel.XRelQty * Part.NetWeight) as [Calculated_weight]
from Erp.POHeader as POHeader
inner join Erp.PODetail as PODetail on
POHeader.Company = PODetail.Company
and POHeader.PONum = PODetail.PONUM
and ( PODetail.OpenLine = 1 )
inner join Erp.Part as Part on
PODetail.Company = Part.Company
and PODetail.PartNum = Part.PartNum
inner join Erp.PORel as PORel on
PODetail.Company = PORel.Company
and PODetail.PONUM = PORel.PONum
and PODetail.POLine = PORel.POLine
where (POHeader.OpenOrder = 1)