Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||
ID | |||||||||||
0032234 | |||||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | ||||||
defect | [Openbravo ERP] A. Platform | minor | always | 2016-02-15 14:52 | 2022-02-01 08:05 | ||||||
Reporter | aferraz | View Status | public | ||||||||
Assigned To | Triage Platform Base | ||||||||||
Priority | normal | Resolution | open | Fixed in Version | |||||||
Status | acknowledged | Fix in branch | Fixed in SCM revision | ||||||||
Projection | none | ETA | none | Target Version | |||||||
OS | Linux 64 bit | Database | PostgreSQL | Java version | 1.6.0_18 | ||||||
OS Version | Professional Appliance | Database version | 8.3.9 | Ant version | 1.7.1 | ||||||
Product Version | SCM revision | ||||||||||
Review Assigned To | |||||||||||
Web browser | |||||||||||
Modules | Core | ||||||||||
Regression level | |||||||||||
Regression date | |||||||||||
Regression introduced in release | |||||||||||
Regression introduced by commit | |||||||||||
Triggers an Emergency Pack | No | ||||||||||
Summary | 0032234: isNull filter is not working correctly in property fields | ||||||||||
Description | isNull filter (Advance Filtering) is not working correctly in property fields. | ||||||||||
Steps To Reproduce | As F&B Admin: - Create a Sales Order for "Alimentos y Supermercados, S.A" business partner and invoice terms "Immediate". Add a line for "Agua sin Gas 1L" product and quantity=2. Book it. Add a payment. - Create a Sales Invoice for "Alimentos y Supermercados, S.A" business partner. Create lines from previous order. Update line for "Agua sin Gas 1L" product and set quantity=1. Complete it. - Navigate to previous created Payment In. Move to Lines tab and realize there are two records, one with non empty Invoice No. and the other one with empty Invoice No. Set "!#" filter in Invoice No. column and realize row with non empty Invoice No. appears. Set "#" filter in Invoice No. column and realize no row is shown while row with empty Invoice No. should appear. | ||||||||||
Proposed Solution | Try to resolve joins in AdvancedQueryBuilder in order to avoid the adding of the cross joins due to the usage of the navigation properties (See notes). resolveJoins() method can be used to replace the property path with the corresponding alias | ||||||||||
Tags | No tags attached. | ||||||||||
Attached Files | |||||||||||
Relationships [ Relation Graph ] [ Dependency Graph ] | ||||||||
|
Notes | |
(0084268) caristu (developer) 2016-02-16 17:23 |
The Invoice No. is a property field. The generated query tries to access it: e.invoicePaymentSchedule.invoice.documentNo As it is a derived property hibernate adds automatically some cross joins in order to retrieve the derived information. Using the following HQL query: select e.id from FIN_Payment_ScheduleDetail as e left join e.invoicePaymentSchedule as join_2 left join join_2.invoice as join_3 where e.invoicePaymentSchedule.invoice.documentNo is null order by e.creationDate desc The resulting SQL is: select fin_paymen0_.FIN_Payment_Scheduledetail_ID as col_0_0_ from FIN_Payment_ScheduleDetail fin_paymen0_ left outer join FIN_Payment_Schedule fin_paymen1_ on fin_paymen0_.FIN_Payment_Schedule_Invoice=fin_paymen1_.Fin_Payment_Schedule_ID left outer join C_Invoice invoice2_ on fin_paymen1_.C_Invoice_ID=invoice2_.C_Invoice_ID cross join FIN_Payment_Schedule fin_paymen3_ cross join C_Invoice invoice4_ where fin_paymen0_.FIN_Payment_Schedule_Invoice=fin_paymen3_.Fin_Payment_Schedule_ID and fin_paymen3_.C_Invoice_ID=invoice4_.C_Invoice_ID and (invoice4_.DocumentNo is null) order by fin_paymen0_.Created desc with those cross joins the rows which does not have an invoice related to the schedule are not returned. This is why the filtering is not working. If we do not use the derived property in the HQL: select e.id from FIN_Payment_ScheduleDetail as e left join e.invoicePaymentSchedule as join_2 left join join_2.invoice as join_3 order by e.creationDate desc The resulting SQL does not use those cross joins: select fin_paymen0_.FIN_Payment_Scheduledetail_ID as col_0_0_ from FIN_Payment_ScheduleDetail fin_paymen0_ left outer join FIN_Payment_Schedule fin_paymen1_ on fin_paymen0_.FIN_Payment_Schedule_Invoice=fin_paymen1_.Fin_Payment_Schedule_ID left outer join C_Invoice invoice2_ on fin_paymen1_.C_Invoice_ID=invoice2_.C_Invoice_ID order by fin_paymen0_.Created desc |
(0085516) hgbot (developer) 2016-04-08 10:59 |
Repository: tools/automation/int Changeset: e19396add870a6d4288aa6d6921d5fd684c10553 Author: Alvaro Ferraz <alvaro.ferraz <at> openbravo.com> Date: Wed Feb 17 19:07:43 2016 +0100 URL: http://code.openbravo.com/tools/automation/int/rev/e19396add870a6d4288aa6d6921d5fd684c10553 [^] Fix PRORegression31873Out1 & SALRegression31873In1 until issue 32234 is fixed --- M src-test/com/openbravo/test/integration/erp/modules/functionalteam/procurement/testsuites/PRO_Regressions/PRORegression31873Out1.java M src-test/com/openbravo/test/integration/erp/modules/functionalteam/sales/testsuites/SAL_Regressions/SALRegression31873In1.java --- |
Issue History | |||
Date Modified | Username | Field | Change |
2016-02-15 14:52 | aferraz | New Issue | |
2016-02-15 14:52 | aferraz | Assigned To | => platform |
2016-02-15 14:52 | aferraz | Modules | => Core |
2016-02-15 14:52 | aferraz | Triggers an Emergency Pack | => No |
2016-02-15 14:54 | aferraz | Steps to Reproduce Updated | View Revisions |
2016-02-15 15:15 | aferraz | Regression level | => Production - Confirmed Stable |
2016-02-16 17:23 | caristu | Note Added: 0084268 | |
2016-02-16 17:26 | caristu | Assigned To | platform => caristu |
2016-02-16 17:26 | caristu | Status | new => acknowledged |
2016-02-16 17:32 | caristu | Regression level | Production - Confirmed Stable => |
2016-02-16 17:32 | caristu | Status | acknowledged => scheduled |
2016-02-16 18:44 | caristu | Proposed Solution updated | |
2016-02-17 08:59 | alostale | Assigned To | caristu => platform |
2016-02-17 08:59 | alostale | Status | scheduled => acknowledged |
2016-02-17 08:59 | alostale | Target Version | 3.0PR16Q2 => |
2016-02-17 09:41 | caristu | Summary | Advance Filtering is not working correctly in some columns => isNull filter is not working correctly in property fields |
2016-02-17 09:41 | caristu | Description Updated | View Revisions |
2016-02-17 09:41 | caristu | Proposed Solution updated | |
2016-02-17 09:42 | caristu | Proposed Solution updated | |
2016-04-08 10:59 | hgbot | Checkin | |
2016-04-08 10:59 | hgbot | Note Added: 0085516 | |
2016-09-07 19:44 | caristu | Relationship added | related to 0033923 |
2022-02-01 08:05 | alostale | Assigned To | platform => Triage Platform Base |
Copyright © 2000 - 2009 MantisBT Group |