[OpenVPMS Developers] 1.6b3 genbalance error
Funnies: a) I am running genbalance after loading the payments ,and debit & credit adjustments but NOT the charges - hence the account balances are all negative and the failing OTC balance is around -$3,600,000 [these are Hong Kong dollars]
b) the kettle loader step is loading the data into the OTC accounts as though they were normal customer accounts [I inserted 3 records in etl_log that map the entity id's for the the OTC accounts to customers 101,102 & 103 and adjusted the RxWorks customer number/clinic number from 1/1, 1/2 & 1/3 to 101, 102 & 103]
The extract from the genbalance log is given below.
If required I could provide the database prior (or after) running genbalance (the self-contained dump is around 370MB) or anything else required.
Regards, Tim
> > >18:20:05,772 INFO Generating account balance for Edwards, Lucinda, >ID=14282 >18:20:05,788 INFO Processed 3 of 3 acts >18:20:05,788 INFO Updated account balance from 0 to -4785.00 >18:20:05,788 INFO Generating account balance for Edwards, Rebecca, >ID=14132 >18:20:05,803 INFO Processed 1 of 1 acts >18:20:05,803 INFO Updated account balance from 0 to -1250.00 >18:20:05,803 INFO Generating account balance for EIAH Counter Sales, >ID=161 >18:51:53,885 ERROR Failed to generate account balance for EIAH Counter Sales >org.openvpms.component.business.service.archetype.ArchetypeServiceException: >Failed to save a collection of 33,573 objects. > at >org.openvpms.component.business.service.archetype.ArchetypeService.save(ArchetypeService.java:545) > at >org.openvpms.component.business.service.archetype.ArchetypeService.save(ArchetypeService.java:513) > at >org.openvpms.archetype.rules.finance.account.CustomerBalanceGenerator.save(CustomerBalanceGenerator.java:265) > at >org.openvpms.archetype.rules.finance.account.CustomerBalanceGenerator.generate(CustomerBalanceGenerator.java:147) > at >org.openvpms.archetype.tools.account.AccountBalanceTool.generate(AccountBalanceTool.java:153) > at >org.openvpms.archetype.tools.account.AccountBalanceTool.generate(AccountBalanceTool.java:288) > at >org.openvpms.archetype.tools.account.AccountBalanceTool.generate(AccountBalanceTool.java:128) > at >org.openvpms.archetype.tools.account.AccountBalanceTool.main(AccountBalanceTool.java:261) >Caused by: >org.openvpms.component.business.dao.im.common.IMObjectDAOException: Failed >to save a collection of objects > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.save(IMObjectDAOHibernate.java:191) > at >org.openvpms.component.business.service.archetype.ArchetypeService.save(ArchetypeService.java:542) > ... 7 more >Caused by: java.lang.IllegalArgumentException: Invalid argument >'archetypeId' > at >org.openvpms.component.business.domain.im.common.IMObjectReference.(IMObjectReference.java:111) > at >org.openvpms.component.business.dao.hibernate.im.common.IMObjectDOImpl.getObjectReference(IMObjectDOImpl.java:180) > at >org.openvpms.component.business.dao.hibernate.im.common.IMObjectDOImpl.equals(IMObjectDOImpl.java:329) > at java.util.HashMap.put(Unknown Source) > at >org.openvpms.component.business.dao.hibernate.im.common.Context.add(Context.java:262) > at >org.openvpms.component.business.dao.hibernate.im.common.IMObjectAssembler.assemble(IMObjectAssembler.java:109) > at >org.openvpms.component.business.dao.hibernate.im.common.CompoundAssembler.assemble(CompoundAssembler.java:90) > at >org.openvpms.component.business.dao.hibernate.im.common.AbstractAssembler.getDO(AbstractAssembler.java:50) > at >org.openvpms.component.business.dao.hibernate.im.common.SetAssembler.assembleDO(SetAssembler.java:142) > at >org.openvpms.component.business.dao.hibernate.im.act.AbstractActAssembler.assembleDO(AbstractActAssembler.java:91) > at >org.openvpms.component.business.dao.hibernate.im.act.FinancialActAssembler.assembleDO(FinancialActAssembler.java:56) > at >org.openvpms.component.business.dao.hibernate.im.act.FinancialActAssembler.assembleDO(FinancialActAssembler.java:34) > at >org.openvpms.component.business.dao.hibernate.im.common.IMObjectAssembler.assemble(IMObjectAssembler.java:113) > at >org.openvpms.component.business.dao.hibernate.im.common.CompoundAssembler.assemble(CompoundAssembler.java:90) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.save(IMObjectDAOHibernate.java:879) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.save(IMObjectDAOHibernate.java:897) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.access$100(IMObjectDAOHibernate.java:98) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate$2.doInHibernate(IMObjectDAOHibernate.java:186) > at >org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406) > at >org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:339) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate$9$1.doInHibernate(IMObjectDAOHibernate.java:1086) > at >org.springframework.orm.hibernate3.HibernateTemplate.doExecute(HibernateTemplate.java:406) > at >org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:339) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate$9.doInTransaction(IMObjectDAOHibernate.java:1082) > at >org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.update(IMObjectDAOHibernate.java:1080) > at >org.openvpms.component.business.dao.hibernate.im.IMObjectDAOHibernate.save(IMObjectDAOHibernate.java:183) > ... 8 more >18:51:53,905 INFO Generating account balance for Einhauser, Marian, >ID=8528 >18:51:53,922 INFO Processed 2 of 2 acts >18:51:53,923 INFO Updated account balance from 0 to -7910.00 >18:51:53,923 INFO Generating account balance for Einheuser, Marion, >ID=12814 >18:51:54,163 INFO Processed 65 of 65 acts >18:51:54,163 INFO Updated account balance from 0 to -58331.00 > > >
_______________________________________________ OpenVPMS Developers Mailing List developers@lists.openvpms.org To unsubscribe or change your subscription visit: http://lists.openvpms.org/listinfo/developers Posts from this mailing list can be viewed online and replied to in the OpenVPMS Developer's forum- http://tinyurl.com/openvdf
Re: [OpenVPMS Developers] 1.6b3 genbalance error - addendum
As an addendum/postscript to the above, I encountered the same "Invalid argument 'archetypeId'" error running a kettle transform to load invoice transactions. The log extract is below.
However, when I turned on more logging to try and see where the problem is occuring (to see if there is anything peculiar in the record being processed when the error occurred), the error did not appear.
I then removed the extra logging and re-ran (after resetting the database to the point before the transactions were loaded). Again - no error !!!
Regards, Tim
If it is of any use, here are the Tx-invoice OPV loader transform step mappings (oID is set as the "ID Field name" in the header):