Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0049244Openbravo ERP01. General setuppublic2022-05-06 09:272022-05-23 13:33
shankarb 
Triage Omni OMS 
normalmajorhave not tried
closedno change required 
30Openbravo Appliance 14.04
 
 
aferraz
Core
No
0049244: Business Partner Search Key accepts duplicate values if it has trailing spaces
If the search key field in Business Partner window contains trailing spaces (before or at the end), then the unique key constraint does not validate duplicate values.
1. Create one business partner with search key "Test".
2. Create another business partner with search key "Test ".
3. Notice that unique key constraint does not prevent saving the record.
No tags attached.
Issue History
2022-05-06 09:27shankarbNew Issue
2022-05-06 09:27shankarbAssigned To => Triage Omni OMS
2022-05-06 09:27shankarbModules => Core
2022-05-06 09:27shankarbTriggers an Emergency Pack => No
2022-05-09 10:59shankarbNote Added: 0137071
2022-05-09 10:59shankarbSeverityminor => major
2022-05-23 13:33aferrazReview Assigned To => aferraz
2022-05-23 13:33aferrazNote Added: 0137611
2022-05-23 13:33aferrazStatusnew => closed
2022-05-23 13:33aferrazResolutionopen => no change required

Notes
(0137071)
shankarb   
2022-05-09 10:59   
Changing the severity because of customer escalation
(0137611)
aferraz   
2022-05-23 13:33   
Unique constraint is working fine as "Test" and "Test " are different values.
In case a unique constraint validation wants to be implemented doing a trim of the entered value, a custom EntityPersistenceEventObserver can be defined: http://wiki.openbravo.com/wiki/How_to_implement_a_business_event_handler [^]