Openbravo Issue Tracking System - Openbravo ERP |
View Issue Details |
|
ID | Project | Category | View Status | Date Submitted | Last Update |
0044043 | Openbravo ERP | A. Platform | public | 2020-05-12 13:55 | 2022-02-28 13:57 |
|
Reporter | inigo_lerga | |
Assigned To | Triage Omni OMS | |
Priority | normal | Severity | minor | Reproducibility | have not tried |
Status | new | Resolution | open | |
Platform | | OS | 5 | OS Version | |
Product Version | | |
Target Version | | Fixed in Version | | |
Merge Request Status | |
Review Assigned To | dmiguelez |
OBNetwork customer | |
Web browser | |
Modules | Core |
Support ticket | |
Regression level | |
Regression date | |
Regression introduced in release | |
Regression introduced by commit | |
Triggers an Emergency Pack | No |
|
Summary | 0044043: Change in query from OBQuery to OBCriteria needed in ManageVariantsDS.java |
Description | In order to avoid non-constant HQLs and dynamic parts previously considered 'safe', it has been decided that a change from OBQuery to OBCriteria can separate the data from the code itself, solving the associated issues related to this matter. |
Steps To Reproduce | - |
Proposed Solution | - |
Additional Information | |
Tags | No tags attached. |
Relationships | |
Attached Files | |
|
Issue History |
Date Modified | Username | Field | Change |
2020-05-12 13:55 | inigo_lerga | New Issue | |
2020-05-12 13:55 | inigo_lerga | Assigned To | => inigo_lerga |
2020-05-12 13:55 | inigo_lerga | Modules | => Core |
2020-05-12 13:55 | inigo_lerga | Triggers an Emergency Pack | => No |
2020-05-12 13:56 | inigo_lerga | Status | new => scheduled |
2020-05-13 10:00 | inigo_lerga | Note Added: 0119800 | |
2020-05-14 11:12 | inigo_lerga | Review Assigned To | => dmiguelez |
2020-05-14 11:12 | inigo_lerga | Note Added: 0119860 | |
2020-05-14 11:12 | inigo_lerga | Status | scheduled => closed |
2020-05-14 11:12 | inigo_lerga | Resolution | open => invalid |
2020-05-14 15:07 | dmiguelez | Assigned To | inigo_lerga => Triage Finance |
2020-05-14 15:07 | dmiguelez | Note Added: 0119883 | |
2020-05-14 15:07 | dmiguelez | Status | closed => new |
2020-05-14 15:07 | dmiguelez | Resolution | invalid => open |
2020-05-14 15:07 | dmiguelez | Type | defect => design defect |
2020-05-14 15:40 | dmiguelez | Note Added: 0119884 | |
2022-02-28 13:57 | vmromanos | Assigned To | Triage Finance => Triage Omni OMS |
Notes |
|
(0119800)
|
inigo_lerga
|
2020-05-13 10:00
|
|
--Test Plan Mantis--
As the F&B International Group Admin role:
- Go Product window and create a new record with any Search Key and
name desired. Check the Is Generic checkbox.
Press the Manage Variants button.
#In this moment the modified code is executed, but not the query#
- Go to Characteristic window and create a new record with name Color
and marked as Variant.
Go to Value Tab and create a new record with name Blue.
Create another record with name Red.
Save the record.
- Again in the Product window, create a new record with any Search Key and
name desired. Check the Is Generic checkbox.
Go to Characteristics Tab and create a new record with the previously created
Color Characteristic marked as Variant.
Go to Characteristic Configuration SubTab and create one record for
each Characteristic Value (Red and Bue).
Save the record.
Press the Manage Variants button.
#In this moment the modified query is executed and two records are shown in
the grid# |
|
|
(0119860)
|
inigo_lerga
|
2020-05-14 11:12
|
|
--- This Issue is rejected ---
The hql contains subqueries that are not a good fit for this type of modification.
The only way to execute the query with OBCriteria would be to separate each subquery in its own OBCriteria.
This would cause performance Issues, as products usually have registered a considerable amount of characteristics and it would be needed to do one OBCriteria query for each one of them. |
|
|
|
This issue can be fixed, but it needs an important refactor of the existing functionality to avoid the mentioned performance issues.
That is why it has been moved to design defect |
|
|
|
The real problem is the "and exists ()" clauses added to the query.
As of now we do not know how, or if it is possible, to do it using a Criteria instead of an hql query. |
|