BAQ Help


This BAQ was working until last week. We went through virtualizing our Epicor server, then we split it, and increased the RAM to 96GB per VM. I also checked the typical timeout settings and everything is set to at least 500. So, I figured it must be something in the BAQ that is not allowing it to run anymore int eh new setup.

Here is the query:

	[OrderRel].[ReqDate] as [OrderRel_ReqDate],
	[OrderRel].[OrderNum] as [OrderRel_OrderNum],
	[OrderRel].[OrderLine] as [OrderRel_OrderLine],
	[OrderRel].[OrderRelNum] as [OrderRel_OrderRelNum],
	[Customer].[Name] as [Customer_Name],
	[OrderRel].[PartNum] as [OrderRel_PartNum],
	[OrderRel].[OurReqQty] as [OrderRel_OurReqQty],
	[JobProd].[JobNum] as [JobProd_JobNum],
	[OrderDtl].[JobID_c] as [OrderDtl_JobID_c],
	[ShipVia].[Description] as [ShipVia_Description],
	[JobHead].[SchedCode] as [JobHead_SchedCode],
	[OrderRel].[IUM] as [OrderRel_IUM]
from Erp.OrderRel as OrderRel
inner join Erp.OrderHed as OrderHed on 
	OrderRel.Company = OrderHed.Company
	and OrderRel.OrderNum = OrderHed.OrderNum
	and ( OrderHed.OrderHeld = False  )

inner join Erp.Customer as Customer on 
	OrderHed.Company = Customer.Company
	and OrderHed.BTCustNum = Customer.CustNum
left outer join Erp.JobProd as JobProd on 
	OrderRel.OrderNum = JobProd.OrderNum
	and OrderRel.OrderLine = JobProd.OrderLine
	and OrderRel.OrderRelNum = JobProd.OrderRelNum
	 OrderRel.Company = JobProd.Company
left outer join Erp.JobHead as JobHead on 
	JobProd.Company = JobHead.Company
	and JobProd.JobNum = JobHead.JobNum
inner join Erp.OrderDtl as OrderDtl on 
	OrderRel.Company = OrderDtl.Company
	and OrderRel.OrderNum = OrderDtl.OrderNum
	and OrderRel.OrderLine = OrderDtl.OrderLine
inner join Erp.ShipVia as ShipVia on 
	OrderRel.Company = ShipVia.Company
	and OrderRel.ShipViaCode = ShipVia.ShipViaCode
where (OrderRel.OpenRelease = TRUE)
order by OrderRel.ReqDate, OrderRel.PartNum

Is it giving an error or timing out? If it’s timing out you could try the OrderHed.Company = CurrentCompany trick.

1 Like

I actually removed the table as it wasn’t pulling info in. I built 2 years ago or so and I was new to Epicor a bit. Thus I used it as a link between tables. Today I know better!..Well, when its possible! LOL!!