[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Error when trying to mark AR as paid



On Mon, Sep 8, 2008 at 5:39 PM, Roberto C. Sánchez <..hidden..> wrote:
> I am running a LedgerSMB install in a test environment as I plan to move
> over from SQL-Ledger.  I am trying to keep the two installs in sync, so
> whatever transactions I perform in the SQL-Ledger install I also perform
> in the LedgerSMB install.
>
> I have an open AR.  When I enter the payment in SQL-Ledger, I enter the
> transaction, and then under "Payments" I enter the date and ammount.  I
> then click "Update" and "Post".  When I click "Post", I get a warning
> about posting an existing transaction, but it goes through and the AR is
> showed as closed and the amount of money shows up in the checking
> account balance.

Better way:

Cash/Receipt or Cash/Receipts

>
> When I try the same thing with LedgerSMB, I get this error right after
> clicking through the warning:
>
> DBD::Pg::st execute failed: ERROR: duplicate key violates unique constraint "transactions_pkey"
> Error!
>
> INSERT INTO ar (id, customer_id) VALUES (?, ?)
> ERROR: duplicate key violates unique constraint "transactions_pkey"
>
> Why might that be?

THere is a known bug for which the SQL script
sql/fixes/transactions_pkey_repost.sql corrects
However, be advised that reposting invoices is *not* gaap compliant
and ideally you should not need to apply the fix.  There are also
known issues that happen with reposting invoices including issues that
can occur with COGS.  There are no accepted accounting fixes because
this is not an accepted accounting practice :-)

Best Wishes,
Chris Travers