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

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0029385
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformminoralways2015-03-24 10:012015-03-27 02:12
ReportercaristuView Statuspublic 
Assigned Toalostale 
PriorityimmediateResolutionfixedFixed in Version3.0PR15Q2
StatusclosedFix in branchFixed in SCM revision088b4114ac74
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product Version3.0PR14Q2.6SCM revision 
Review Assigned ToAugustoMauch
Web browser
ModulesCore
Regression levelProduction - Confirmed Stable
Regression date2014-01-07
Regression introduced in release3.0PR14Q2
Regression introduced by commithttp://code.openbravo.com/erp/devel/pi/rev/46ec5ec2839da79ae27a5225c105c85ecde1cf6a [^]
Triggers an Emergency PackNo
Summary

0029385: Distinct parameter is not working in JSON REST web services

DescriptionDistinct parameter is not working in JSON REST web services. An error like the following is thrown when using it:

{"response":{"data":[{"response":{"status":-1,"error":{"message":"Exception when creating query select me from Product as me where ( exists (select 1 from Product inner join null.organization as i where i = me and e.organization.id in ('E443A31992CB4635AFCAEABE7183CE85', '0', 'DC206C91AA6A4897B44DA897936E0EC3', '7BABA5FF80494CAFA54DEBD22EC46F01', 'BAE22373FEBE4CCCA24517E23F0C8A48', '19404EAD144C49A0AF37D54377CF452D', 'B843C30461EA4501935CB1D125C9C25A', '2E60544D37534C0B89E765FE29BC0B43') and e.client.id in ('23C59575B9CF467C9620760EB255B389', '0')) )order by me.name","messageType":"Error","title":""},"totalRows":0}}
Steps To Reproduce1) Do the following web service call

https://livebuilds.openbravo.com/erp_pi_pgsql/org.openbravo.service.json.jsonrest/Product?_distinct=organization [^]

Notice that the error is returned
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
depends on backport 00294283.0PR15Q1.3 closedalostale Distinct parameter is not working in JSON REST web services 
caused by defect 00251823.0PR14Q2 closedalostale Query in org drop down in the list field is having bad performance 

-  Notes
(0076012)
hgbot (developer)
2015-03-26 15:22

Repository: erp/devel/pi
Changeset: 3c52c4d0b73b20527effadf0ce4676bd7f638891
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Thu Mar 26 15:15:16 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/3c52c4d0b73b20527effadf0ce4676bd7f638891 [^]

related to bug 29385: Distinct parameter is not working in JSON REST web services

  Added test cases

---
M src-test/src/org/openbravo/test/webservice/JSONWebServices.java
---
(0076013)
hgbot (developer)
2015-03-26 15:22

Repository: erp/devel/pi
Changeset: 088b4114ac745dad78496622bd588c1a8a1423b9
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Thu Mar 26 15:21:18 2015 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/088b4114ac745dad78496622bd588c1a8a1423b9 [^]

fixed bug 29385: Distinct parameter is not working in JSON REST web services

  Using _distinct property in JSON REST webservices resulted in an incorrectly
  generated query. There were 2 problems:

   - Entity name for was set in the fetch method, after the refactor done to fix
     issue 0025182, entity is different in case of using _distinct, and it is managed
     by QueryService.
   - This refactor also requires of using aliases to work

---
M modules/org.openbravo.service.json/src/org/openbravo/service/json/DefaultJsonDataService.java
M modules/org.openbravo.service.json/src/org/openbravo/service/json/JsonRestServlet.java
---
(0076031)
AugustoMauch (administrator)
2015-03-26 18:13

Code reviewed and verified in pi@9a240957107d
(0076042)
hudsonbot (developer)
2015-03-27 02:12

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/b8858c8b542b [^]
Maturity status: Test
(0076043)
hudsonbot (developer)
2015-03-27 02:12

A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/b8858c8b542b [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2015-03-24 10:01 caristu New Issue
2015-03-24 10:01 caristu Assigned To => platform
2015-03-24 10:01 caristu Modules => Core
2015-03-24 10:01 caristu Regression level => Production - Confirmed Stable
2015-03-24 10:01 caristu Triggers an Emergency Pack => No
2015-03-24 10:01 caristu Issue Monitored: networkb
2015-03-24 10:06 caristu Resolution time => 1433109600
2015-03-26 12:01 alostale Status new => scheduled
2015-03-26 12:01 alostale Assigned To platform => alostale
2015-03-26 14:54 alostale Relationship added caused by 0025182
2015-03-26 14:55 alostale Review Assigned To => AugustoMauch
2015-03-26 14:55 alostale Regression date => 2014-01-07
2015-03-26 14:55 alostale Regression introduced in release => 3.0PR14Q2
2015-03-26 14:55 alostale Regression introduced by commit => http://code.openbravo.com/erp/devel/pi/rev/46ec5ec2839da79ae27a5225c105c85ecde1cf6a [^]
2015-03-26 15:22 hgbot Checkin
2015-03-26 15:22 hgbot Note Added: 0076012
2015-03-26 15:22 hgbot Checkin
2015-03-26 15:22 hgbot Note Added: 0076013
2015-03-26 15:22 hgbot Status scheduled => resolved
2015-03-26 15:22 hgbot Resolution open => fixed
2015-03-26 15:22 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/088b4114ac745dad78496622bd588c1a8a1423b9 [^]
2015-03-26 18:13 AugustoMauch Note Added: 0076031
2015-03-26 18:13 AugustoMauch Status resolved => closed
2015-03-26 18:13 AugustoMauch Fixed in Version => 3.0PR15Q2
2015-03-27 02:12 hudsonbot Checkin
2015-03-27 02:12 hudsonbot Note Added: 0076042
2015-03-27 02:12 hudsonbot Checkin
2015-03-27 02:12 hudsonbot Note Added: 0076043


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker