Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0027246 | Openbravo ERP | 00. Application dictionary | public | 2014-07-31 09:30 | 2014-08-17 15:32 |
|
Reporter | mtaal | |
Assigned To | AugustoMauch | |
Priority | normal | Severity | major | Reproducibility | have not tried |
Status | closed | Resolution | fixed | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | | Fixed in Version | | |
Merge Request Status | |
Review Assigned To | mtaal |
OBNetwork customer | No |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0027246: Error when setting count function in analytics window |
Description | See screenshot, apparently this query has an error:
select count(e.salesOrder.documentNo + join_1.orderDate + join_1.grandTotalAmount) from OBANALY_FACT_ORDER as e left join e.salesOrderLine as join_0 left join join_0.salesOrder as join_1 where ( ( e.lineCost > :alias_0 ) ) and e.organization.id in ('BE0AC4CFA26F4F408FD407033E4BFCF9', '9DB2E1269F0149EDBD0D00C53C7DAC73', '4525CC3279774C89AC745FE7627C701C', '504FD243C72E40ABBA834C73B5667EF7', '7C4A8703014F416CB5222163B9DB1BFE', '05830B2BCB9D477B9A3F22082634DFFF', '6C32D1DF2D504ADCA4FC5ABCFCDA18FF', 'BF22A3C7C9CD4F70814D871A2E4EE7A2', '6049CE77D04845969D328CA3731F033F', '2AA41098B0AA47C791B92AE5B1D40A99', 'DDD786B5320F4B19B19661A9CDBF74EA', '18164FB16A334FC8BF449DE217284031', 'E0522AE6B2EA446D85FD69B5CC416826', 'C11EF9BFAC03464C9B9E6925C0EE7F8C', 'C11077EB595D403AA87AFEBCC45CD83D', '387E977F25204A4DB5B6BED50554B168', '02BC27FC439147F6BB1DF655D03623C0', 'FB6777E278FD4ED08F9384450FEA3845', '5F0478879DED4E2CBF387B35A779569E', '0', 'B1269F493B1342BE8B4B75D11B995E0E', '83A0BB79EEDA4ECCB4BCFDF1A9A09466', 'C069750FD29C46BF98A0F1126496C711') and e.client.id in ('A65074D0843147BEB4F13FF007B52F0A', '0') |
Steps To Reproduce | - open analytics details window
- set a summary function on a column
- reload |
Proposed Solution | |
Additional Information | |
Tags | No tags attached. |
Relationships | |
Attached Files | Selection_009.png (207,546) 2014-07-31 09:30 https://issues.openbravo.com/file_download.php?file_id=7111&type=bug

AnalyticsCount.png (131,519) 2014-08-12 15:11 https://issues.openbravo.com/file_download.php?file_id=7131&type=bug

|
|
Issue History |
Date Modified | Username | Field | Change |
2014-07-31 09:30 | mtaal | New Issue | |
2014-07-31 09:30 | mtaal | Assigned To | => mtaal |
2014-07-31 09:30 | mtaal | File Added: Selection_009.png | |
2014-07-31 09:30 | mtaal | OBNetwork customer | => No |
2014-08-12 15:09 | AugustoMauch | Assigned To | mtaal => AugustoMauch |
2014-08-12 15:10 | AugustoMauch | Note Added: 0069316 | |
2014-08-12 15:10 | AugustoMauch | Status | new => feedback |
2014-08-12 15:11 | AugustoMauch | File Added: AnalyticsCount.png | |
2014-08-12 15:14 | mtaal | Note Added: 0069317 | |
2014-08-13 08:30 | AugustoMauch | Note Added: 0069332 | |
2014-08-13 08:30 | AugustoMauch | Status | feedback => new |
2014-08-13 10:07 | AugustoMauch | Project | Modules => Openbravo ERP |
2014-08-13 10:10 | AugustoMauch | Note Added: 0069336 | |
2014-08-13 10:16 | AugustoMauch | Issue Monitored: mtaal | |
2014-08-13 10:16 | AugustoMauch | Review Assigned To | => mtaal |
2014-08-13 10:16 | AugustoMauch | Modules | => Core |
2014-08-13 10:16 | AugustoMauch | Triggers an Emergency Pack | => No |
2014-08-13 10:16 | AugustoMauch | Category | Analytics => 00. Application dictionary |
2014-08-13 10:16 | hgbot | Checkin | |
2014-08-13 10:16 | hgbot | Note Added: 0069337 | |
2014-08-13 10:16 | hgbot | Status | new => resolved |
2014-08-13 10:16 | hgbot | Resolution | open => fixed |
2014-08-13 10:16 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/ce5524b59abfc64fd83bfb86b4f919e51ca3c897 [^] |
2014-08-14 04:01 | hudsonbot | Checkin | |
2014-08-14 04:01 | hudsonbot | Note Added: 0069360 | |
2014-08-17 15:32 | mtaal | Note Added: 0069424 | |
2014-08-17 15:32 | mtaal | Status | resolved => closed |
Notes |
|
|
I can't reproduce the issue. The count summary function works properly in the Analytics Sales Detail View window, see attached screenshot. |
|
|
(0069317)
|
mtaal
|
2014-08-12 15:14
|
|
Hey Augusto,
One thing is that I had set a filter in the cost colum with: > 0
so it shows all the records with cost larger than 0
Can you try that?
gr. Martin |
|
|
|
I can reproduce by setting the summary field in the Sales Order Line column. |
|
|
|
This happens when the column used in the count summary function points to a table that has at least one non-primitive identifier property that points to another table that has more than one identifier property (primitive or non-primitive).
In this case, the identifier of Sales Order Line uses the identifier of Sales Order, which has three identifier properties. |
|
|
(0069337)
|
hgbot
|
2014-08-13 10:16
|
|
Repository: erp/devel/pi
Changeset: ce5524b59abfc64fd83bfb86b4f919e51ca3c897
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Wed Aug 13 10:15:49 2014 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/ce5524b59abfc64fd83bfb86b4f919e51ca3c897 [^]
Fixes issue 27246: Error when setting count function in analytics window
The problem was that a select clause like this was being used in a HQL query:
* select count(e.salesOrder.documentNo + join_1.orderDate + join_1.grandTotalAmount) from ...
Property concatenation is not supported in a count function, it does not even make sense. To fix this, the addSelectFunctionPart method of AdvancedQueryBuilder has been updated so that '*' is always used inside the count function.
---
M modules/org.openbravo.service.json/src/org/openbravo/service/json/AdvancedQueryBuilder.java
---
|
|
|
|
|
|
(0069424)
|
mtaal
|
2014-08-17 15:32
|
|
|