Hello,
I am very new to Epicor, BAQ and Calculations.
I created a Calculated Field to show PartNum_PONum_PO$ in one field. I checked the Syntax within the Calculated Filed SQL Editor and Analyze and the Syntax is OK. However, when I run Test, I get the following error:
Severity: Error, Text: Bad SQL statement.
Review the server event logs for details.
Query returned 0 row(s).
Query has no more records to return.
Query execution total time: 7866.6191 ms.
My calculation looks like this: (Part.PartNum+ββ+OrderHed.PONum+ββ+OrderHed.DocTotalCharges)
My data type is: nvarchar
Your syntax might work, but thatβs not how I do mine in a BAQ. For example, jobs created from our orders use the naming convention of β00β+ OrderNum + β-β + OrderLine + β-β + OrderRel
In trying to connect, Iβm looking for something that starts with 00 then has an order number followed by - and then I donβt care what comes next:
Using LIKE instead or =
CONCAT (β00β,OrderHed.OrderNum,β-β,β%β)
single quotes around the strings, no quotes around the field name, and then quotes around the % wildcard character.
Hopefully you can pull something useful from that.
Your suggestion worked: Concat(Part.PartNum,β','PO β,OrderHed.PONum,ββ,β$β,OrderHed.DocTotalCharges)
The only small issue is with the currency. Instead of seeing $37,112.00, I see $37112.000.