Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0036167
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformmajoralways2017-06-02 10:252017-07-19 12:56
ReporterdmiguelezView Statuspublic 
Assigned Toalostale 
PrioritynormalResolutionfixedFixed in Version3.0PR17Q4
StatusclosedFix in branchFixed in SCM revision485d1a99a09d
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tocaristu
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0036167: Tree view of Tab is not correctly filtered if tab has where clause

DescriptionIf we enable the Tree view of a Tab with hundreds of records, it should work without any additional configuration (A preference can be created to modify this limit, but we should not need to enable it, we are working with less than 1000 records)

However, it is not working properly, the message:"This query criteria returns a number of nodes larger than the established limit. Please enter a more restrictive filter." is shown

It seems that the query is not being filtered properly.
In the Tab, there is a where clause with an expression containing an OR (something like x OR y). It seems that this may be one of the problems, since when building the query for the Tree, it is not isolating this expression between parenthesis, and the final expression looks like x OR y AND z, which does not match the original intent of the filter (x OR y) AND z
Steps To Reproduce1. Apply the given patch (Configures a Tree view in Storage Bins Tab and allows to create 500 additional Bins)
2. Launch InventoryStatusTest.java class to create 500 additional Bins (This can be launched as any other JUnit test)
3. Login as QA Admin
4. Move to Warehouse and Storage Bins || Storage Bin Tab
5. Select any record and click on the Toggle Tree view button
6. The error message is shown
TagsNo tags attached.
Attached Filesdiff file icon issue.diff [^] (4,732 bytes) 2017-06-02 10:25 [Show Content]
diff file icon proposal.diff [^] (1,316 bytes) 2017-06-02 10:25 [Show Content]

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
(0097096)
dmiguelez (developer)
2017-06-02 10:27

An additional diff file has been attached with some fixes to some of the problems we've been able to see. But it is not a final solution.

The problem found and fix was related to how the query was built.
The fix is to isolate the Tab where clause in parentheses to avoid conflicts with the rest of the query that is being created.
(0098088)
hgbot (developer)
2017-07-17 08:19

Repository: erp/devel/pi
Changeset: 485d1a99a09df2e7501b785cd60bff6ea8fe06c4
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Jul 14 13:33:10 2017 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/485d1a99a09df2e7501b785cd60bff6ea8fe06c4 [^]

fixed bug 36167: Tree view is not correctly filtered if tab has where clause

  In case a tab that can be seen in tree mode, has a where clase with any OR, the
  query generated for the tree view, was not applying this wehere clause corretly
  because it didn't take into consideration operator precedence.

  Fixed by isolating tab's where clause in the genereted query.

---
M modules/org.openbravo.service.datasource/src/org/openbravo/service/datasource/LinkToParentTreeDatasourceService.java
---
(0098133)
caristu (developer)
2017-07-19 12:56

Code reviewed + testing OK.

- Issue History
Date Modified Username Field Change
2017-06-02 10:25 dmiguelez New Issue
2017-06-02 10:25 dmiguelez Assigned To => platform
2017-06-02 10:25 dmiguelez File Added: issue.diff
2017-06-02 10:25 dmiguelez Modules => Core
2017-06-02 10:25 dmiguelez Triggers an Emergency Pack => No
2017-06-02 10:25 dmiguelez File Added: proposal.diff
2017-06-02 10:27 dmiguelez Note Added: 0097096
2017-06-02 12:29 dmiguelez Description Updated View Revisions
2017-07-14 13:28 alostale Summary Tree view of Tab is not working with hundreds of records (the limit is supposed to be 1000 by default) => Tree view of Tab is not correctly filtered if tab has where clause
2017-07-14 13:33 alostale Status new => scheduled
2017-07-14 13:33 alostale Assigned To platform => alostale
2017-07-14 13:33 alostale Review Assigned To => caristu
2017-07-17 08:19 hgbot Checkin
2017-07-17 08:19 hgbot Note Added: 0098088
2017-07-17 08:19 hgbot Status scheduled => resolved
2017-07-17 08:19 hgbot Resolution open => fixed
2017-07-17 08:19 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/485d1a99a09df2e7501b785cd60bff6ea8fe06c4 [^]
2017-07-19 12:56 caristu Note Added: 0098133
2017-07-19 12:56 caristu Status resolved => closed
2017-07-19 12:56 caristu Fixed in Version => 3.0PR17Q4


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker