Openbravo Issue Tracking System - Openbravo ERP | |||||
View Issue Details | |||||
ID | Project | Category | View Status | Date Submitted | Last Update |
0023538 | Openbravo ERP | A. Platform | public | 2013-04-12 10:30 | 2013-04-30 21:05 |
Reporter | mirurita | ||||
Assigned To | shankarb | ||||
Priority | high | Severity | major | Reproducibility | always |
Status | closed | Resolution | no change required | ||
Platform | OS | 20 | OS Version | Community Appliance | |
Product Version | pi | ||||
Target Version | Fixed in Version | ||||
Merge Request Status | |||||
Review Assigned To | alostale | ||||
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 | 0023538: Tab whereclause not resolving properly comparations of YesNo (boolean) reference columns. | ||||
Description | 1) As system admin mark FIN_Payment_Proposal.Isreceipt column as stored in session. 2) As system admin go to "Payment Proposal Pick and Edit Lines" window 2.1) Edit the "Pick and Edit Lines" tab whereclause replace e.salesTransaction = false for e.salesTransaction = @FIN_Payment_Proposal.receipt@ 3) compile 4) Go to Payment Proposal window, create a new record and click on "Select Expected Payments" button the value sent to the backend is @FIN_Payment_Proposal.receipt@: false 5) See the error 2483ed25 1794036 [TP-Processor3] ERROR org.openbravo.service.json.DefaultJsonDataService - java.lang.String cannot be cast to java.lang.Boolean java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Boolean at org.hibernate.type.descriptor.java.BooleanTypeDescriptor.unwrap(BooleanTypeDescriptor.java:36) at org.hibernate.type.descriptor.sql.VarcharTypeDescriptor$1.doBind(VarcharTypeDescriptor.java:52) at org.hibernate.type.descriptor.sql.BasicBinder.bind(BasicBinder.java:91) at org.hibernate.type.AbstractStandardBasicType.nullSafeSet(AbstractStandardBasicType.java:282) at org.hibernate.type.AbstractStandardBasicType.nullSafeSet(AbstractStandardBasicType.java:277) at org.hibernate.param.NamedParameterSpecification.bind(NamedParameterSpecification.java:67) at org.hibernate.loader.hql.QueryLoader.bindParameterValues(QueryLoader.java:571) at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1716) at org.hibernate.loader.Loader.doQuery(Loader.java:801) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274) at org.hibernate.loader.Loader.doList(Loader.java:2533) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2276) at org.hibernate.loader.Loader.list(Loader.java:2271) at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:452) at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:363) at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196) at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1268) at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102) at org.openbravo.dal.service.OBQuery.list(OBQuery.java:115) | ||||
Steps To Reproduce | 1) As system admin mark FIN_Payment_Proposal.Isreceipt column as stored in session. 2) As system admin go to "Payment Proposal Pick and Edit Lines" window 2.1) Edit the "Pick and Edit Lines" tab whereclause replace e.salesTransaction = false for e.salesTransaction = @FIN_Payment_Proposal.receipt@ 3) compile 4) Go to Payment Proposal window, create a new record and click on "Select Expected Payments" button the value sent to the backend is @FIN_Payment_Proposal.receipt@: false 5) See the error 2483ed25 1794036 [TP-Processor3] ERROR org.openbravo.service.json.DefaultJsonDataService - java.lang.String cannot be cast to java.lang.Boolean java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Boolean at org.hibernate.type.descriptor.java.BooleanTypeDescriptor.unwrap(BooleanTypeDescriptor.java:36) at org.hibernate.type.descriptor.sql.VarcharTypeDescriptor$1.doBind(VarcharTypeDescriptor.java:52) at org.hibernate.type.descriptor.sql.BasicBinder.bind(BasicBinder.java:91) at org.hibernate.type.AbstractStandardBasicType.nullSafeSet(AbstractStandardBasicType.java:282) at org.hibernate.type.AbstractStandardBasicType.nullSafeSet(AbstractStandardBasicType.java:277) at org.hibernate.param.NamedParameterSpecification.bind(NamedParameterSpecification.java:67) at org.hibernate.loader.hql.QueryLoader.bindParameterValues(QueryLoader.java:571) at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1716) at org.hibernate.loader.Loader.doQuery(Loader.java:801) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274) at org.hibernate.loader.Loader.doList(Loader.java:2533) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2276) at org.hibernate.loader.Loader.list(Loader.java:2271) at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:452) at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:363) at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196) at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1268) at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102) at org.openbravo.dal.service.OBQuery.list(OBQuery.java:115) | ||||
Proposed Solution | the following workaround works: e.salesTransaction = (case when @FIN_Payment_Proposal.receipt@='true' then 'Y' else 'N' end) | ||||
Additional Information | |||||
Tags | No tags attached. | ||||
Relationships | |||||
Attached Files | ![]() https://issues.openbravo.com/file_download.php?file_id=6108&type=bug | ||||
Issue History | |||||
Date Modified | Username | Field | Change | ||
2013-04-12 10:30 | mirurita | New Issue | |||
2013-04-12 10:30 | mirurita | Assigned To | => AugustoMauch | ||
2013-04-12 10:30 | mirurita | Modules | => Core | ||
2013-04-12 10:30 | mirurita | OBNetwork customer | => No | ||
2013-04-12 10:30 | mirurita | Triggers an Emergency Pack | => No | ||
2013-04-16 11:59 | shankarb | Assigned To | AugustoMauch => shankarb | ||
2013-04-23 10:17 | shankarb | File Added: 23538.diff | |||
2013-04-28 08:40 | shankarb | Issue Monitored: AugustoMauch | |||
2013-04-28 08:40 | shankarb | Review Assigned To | => AugustoMauch | ||
2013-04-28 08:40 | shankarb | Status | new => scheduled | ||
2013-04-28 08:40 | shankarb | fix_in_branch | => pi | ||
2013-04-28 09:56 | hgbot | Checkin | |||
2013-04-28 09:56 | hgbot | Note Added: 0058294 | |||
2013-04-28 09:56 | hgbot | Status | scheduled => resolved | ||
2013-04-28 09:56 | hgbot | Resolution | open => fixed | ||
2013-04-28 09:56 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/5e5dd4a8b5c000c0f6ae0f1e8469cd7b6c708200 [^] | ||
2013-04-29 19:37 | hudsonbot | Checkin | |||
2013-04-29 19:37 | hudsonbot | Note Added: 0058312 | |||
2013-04-30 11:10 | hgbot | Checkin | |||
2013-04-30 11:10 | hgbot | Note Added: 0058331 | |||
2013-04-30 11:10 | alostale | Status | resolved => new | ||
2013-04-30 11:10 | alostale | Resolution | fixed => open | ||
2013-04-30 11:14 | alostale | Review Assigned To | AugustoMauch => alostale | ||
2013-04-30 11:14 | alostale | Note Added: 0058332 | |||
2013-04-30 11:14 | alostale | Status | new => closed | ||
2013-04-30 11:14 | alostale | Resolution | open => no change required | ||
2013-04-30 21:05 | hudsonbot | Checkin | |||
2013-04-30 21:05 | hudsonbot | Note Added: 0058390 |
Notes | |||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|
||||
|
|||||
|
|