[
https://issues.jboss.org/browse/TEIIDDES-2382?page=com.atlassian.jira.plu...
]
Barry LaFond edited comment on TEIIDDES-2382 at 11/6/14 2:29 PM:
-----------------------------------------------------------------
Tested with latest code and appears the vague error was related to TEIIDDES-2344, which
was fixed.
Defining the specified SQL in Description validated correctly. No error.
Removing the GROUP BY cust.id; results in: * ERROR: [cust.id] cannot be used outside of
aggregate functions since they are not present in a GROUP BY clause.*
was (Author: blafond):
Tested with latest code and appears the vague error was related to TEIIDDES-2344, which
was fixed.
Defining the specified SQL in Description validated correctly. No error.
No error message for query with aggregate function and no group by
clause
-------------------------------------------------------------------------
Key: TEIIDDES-2382
URL:
https://issues.jboss.org/browse/TEIIDDES-2382
Project: Teiid Designer
Issue Type: Bug
Components: Transformations
Affects Versions: 8.6
Reporter: Jan Stastny
Assignee: Barry LaFond
In designer when defining a table in view model with following transformation query, bad
error message is returned to user.
SELECT cust.id AS customer_id, SUM(ord.amount) AS total_amount
FROM
customers AS cust INNER JOIN orders AS ord
ON cust.id = ord.customer_id
GROUP BY cust.id;
When user forgets to write the GROUP BY clause then error with following message occurs:
"ERROR:ERROR".
When I execute similar query via teeid driver then I get very useful message:
"Error: Remote org.teiid.api.exception.query.QueryValidatorException: Non-constant,
non-aggregate expression cust.id cannot be mixed with aggregate functions and implicit
grouping."
It would be very helpful if Teiid designer gave similar message instead of the
"ERROR:ERROR" one.
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)