Openbravo Issue Tracking System - Modules
View Issue Details
0037443ModulesInitial data loadpublic2017-12-11 10:422022-02-28 13:53
AtulOpenbravo 
Triage Platform Conn 
normalminoralways
newopen 
5
 
 
0037443: Query did not return a unique result error when import Journal Entries using IDL Module
Under some circumstances error is shown as Query did not return a unique result error when import Journal Entries using IDL Module. User can define multiple dimension under General Ledger with type Account.
- Install IDL module and apply reference data set.
- Login as F&B International Group Admin
- Navigate to General Ledger Configuration
- Select record F&B International Group US/A/US Dollar
- Under Dimension Tab, create record as below
  - Sequence No - 50
  - Name - Account 2
  - Type :- Account
  - Account Tree :- F&B EspaƱa, S.A. Account Account
  - Account Element:- 99909 - Cuenta por defecto de otros gastos
- Save Record.
- Navigate to Import process
- Select attached file and Entity as Journal Entry.
- Click on Validate button. Realize that process is executed successfully.
- Select attached file and Entity as Journal Entry.
- Click on Process button.
- Error is raised as

org.hibernate.NonUniqueResultException: query did not return a unique result: 2
    at org.hibernate.impl.AbstractQueryImpl.uniqueElement(AbstractQueryImpl.java:899)
    at org.hibernate.impl.CriteriaImpl.uniqueResult(CriteriaImpl.java:369)
    at org.openbravo.dal.service.OBCriteria.uniqueResult(OBCriteria.java:166)
    at org.openbravo.idl.proc.JournalEntriesProcess.createJournalEntries(JournalEntriesProcess.java:269)
    at org.openbravo.idl.proc.JournalEntriesProcess.internalProcess(JournalEntriesProcess.java:99)
    at org.openbravo.idl.proc.IdlService.finishRecordProcess(IdlService.java:221)
    at org.openbravo.idl.initial_data_load.journalentryjob_0_1.JournalEntryJob.tFileInputDelimited_1Process(JournalEntryJob.java:6527)
    at org.openbravo.idl.initial_data_load.journalentryjob_0_1.JournalEntryJob.runJobInTOS(JournalEntryJob.java:6836)
    at org.openbravo.idl.initial_data_load.journalentryjob_0_1.JournalEntryJob.runJob(JournalEntryJob.java:6762)
    at org.openbravo.idl.proc.JournalEntriesProcess.runJob(JournalEntriesProcess.java:63)
    at org.openbravo.idl.proc.IdlServiceETL.executeImport(IdlServiceETL.java:20)
    at org.openbravo.idl.proc.IdlService.executeProcess(IdlService.java:103)
    at org.openbravo.idl.form.IDL_import.doPost(IDL_import.java:109)
- Restrict user from defining multiple Account Type Dimension in General Ledger Configuration.
- Use setMaxResults(1) before criteriaAcctSchemaElement.uniqueResult() in class JournalEntriesProcess.java
No tags attached.
related to defect 0037444 new Triage Platform Conn IndexOutOf BoundException raised in Journal Entries process in IDL module under some circumstances 
csv Journal_Entries.csv (614) 2017-12-11 10:49
https://issues.openbravo.com/file_download.php?file_id=11359&type=bug
Issue History
2017-12-11 10:42AtulOpenbravoNew Issue
2017-12-11 10:42AtulOpenbravoAssigned To => Triage Finance
2017-12-11 10:43AtulOpenbravoProposed Solution updated
2017-12-11 10:49AtulOpenbravoFile Added: Journal_Entries.csv
2017-12-11 10:57AtulOpenbravoRelationship addedrelated to 0037444
2022-02-28 13:53vmromanosAssigned ToTriage Finance => Triage Platform Conn

There are no notes attached to this issue.