[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
question about modifying/deleting invoices
- Subject: question about modifying/deleting invoices
- From: "Chris Calef" <..hidden..>
- Date: Wed, 17 Sep 2008 00:03:12 +0000
Hello,
I have a question about the process for modifying and deleting invoices. In my current build, I'm getting an SQL error when I try to change an invoice, saying that I'm trying to insert a transaction with a duplicate primary key. Looking into the code I see that reposting an existing invoice calls up IS->delete_invoice, which calls reverse_invoice, which together do a number of things to maintain parts on hand and so forth and then delete relevant entries from invoice, ar, acc_trans, and shipto. However, I'm not seeing anything that deletes from transactions. When a new ar is inserted, apparently using the same id as the old one, the rules for ar dictate that a new transaction also be inserted with the same id, but in my build this transaction is still there from the old one, hence my insert error.
This is probably only an issue in my modified build, but as a non-accountant and relative newbie at lsmb, any insight as to how this process is supposed to work would be most welcome.
Thanks!
Chris Calef