On Tue, Oct 18, 2011 at 7:05 AM, herman vierendeels <[email protected]> wrote: > Hello, > > -- I had to do following extra-steps before being able to upgrade db > without errors: > > dangling acc_trans , invoice > > delete from lsmb12.acc_trans where trans_id in (SELECT trans_id FROM > lsmb12.acc_trans where trans_id not in (select id from lsmb12.ap union > select id from lsmb12.ar union select id from lsmb12.gl) group by > trans_id); > > delete from lsmb12.invoice where trans_id in (SELECT trans_id FROM > lsmb12.invoice where trans_id not in (select id from lsmb12.ap union > select id from lsmb12.ar union select id from lsmb12.gl) group by > trans_id); > > Is this something we should check in sql/upgrade/1.2-pre-upgrade-checks.sql ?
Probably a good idea. Go for it. > > > -- i had to do following extra-step before being able to work with upgraded > db: > > update parts p set expense_accno_id=(select c.id from chart > c,lsmb12.chart lc where c.accno=lc.accno and > lc.id=p.expense_accno_id); > > Should we not adapt import of parts in e.g. sql/upgrade/1.2-1.3-manual.sql > > --INSERT INTO parts SELECT * FROM lsmb12.parts; > > insert into parts select > id,partnumber,description,unit,listprice,sellprice,lastcost,priceupdate,weight,onhand,notes,makemodel,assembly,alternate,rop,inventory_accno_id,income_accno_id, > --expense_accno_id, > (select c.id from chart c,lsmb12.chart lc where c.accno=lc.accno and > lc.id=l12parts.expense_accno_id), > bin,obsolete,bom,image,drawing,microfiche,partsgroup_id,project_id,avgcost > person > from lsmb12.parts l12parts > > idem for inventory_accno_id or income_accno_id ?? yep. Good catch. Yeah, go ahead and fix this. Best Wishes, Chris Travers ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity and more. Splunk takes this data and makes sense of it. Business sense. IT sense. Common sense. http://p.sf.net/sfu/splunk-d2d-oct _______________________________________________ Ledger-smb-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ledger-smb-devel
