Is this the future? We upgraded to 10.2 and immediately users are noticing their error messages are incorrect.
I hope it’s a setting somewhere.
Example: Simple BAQ, when I try to analyze I should get an error about a field not being in a group by or aggregate function or something like that.
The Error I get is:
Severity: Error, Table: , Field: , RowID: , 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: 33.8413 ms.
Whoops … Don’t know what I was thinking in that last post (which I’ve deleted)
When I duplicate your BAQ, I get the expected error of
Severity: Error, Table: , Field: , RowID: , Text: Column ‘Erp.PartPlant.Plant’ is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
For the SQL clause of
select
[PartPlant].[Company] as [PartPlant_Company],
[PartPlant].[Plant] as [PartPlant_Plant]
from Erp.PartPlant as PartPlant
group by [PartPlant].[Company]
Ok, so in 10.2.300.6 when I click on Test I get the same error as @markb_wi, but when I click Analyze it does give me the actual error message. Do you not get the below error @markb_wi when clicking Analyze in your version?
It looks like they didn’t re-order the buttons but the test button used to return the same information the analyze button did. Not a huge deal but I was pretty surprised. Thanks for the help!
Analyze results: Column 'Erp.PartPlant.Plant' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
Test results: Severity: Error, Table: , Field: , RowID: , Text: Column 'Erp.PartPlant.Plant' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause. Query returned 0 row(s). Query has no more records to return. Query execution total time: 13.4291 ms.
10.2.300 includes several Security “Hardening” updates. One of those is that Epicor will no longer return an error generated by SQL back to the end user. The user will get a generic error message while the actual error message is logged.
While this may not be convenient for you power users, it is in line with security “best practices” and as you have found, the information is available via the BAQ Designer.
What if I’m getting
“Syntax is OK”
when I click Analyze… and
“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: 52.9711 ms.”
when I click Test…