[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Error when upgrading 1.2 db to 1.3 db
- Subject: Re: Error when upgrading 1.2 db to 1.3 db
- From: Nigel Titley <..hidden..>
- Date: Tue, 10 Jan 2012 22:56:56 +0000
On 10/01/12 22:02, Erik Huelsmann wrote:
> Hi Nigel,
>> I'm about to add a header at the start, dump a new test copy of the
>> database and try again.
>
> That should do it. Please let us know about your outcome.
OK, I'm now getting a little further on
psql:1.2-1.3-upgrade.sql:38: ERROR: null value in column "country_id"
violates not-null constraint
Looking at the upgrade script this seems to be caused by my using
"United Kingdom" rather than "UK" for the default country.
Fixing this then takes us a lot further on to
psql:1.2-1.3-upgrade.sql:157: ERROR: duplicate key value violates
unique constraint "eca_to_contact_pkey"
and here I get a bit bogged down in the SQL and it would help to have a
pointer to look for.
>> What is the reason for the header association constraint in the
>> migration code? I have to admit that I never saw any reason for header
>> accounts, but that is probably my lack of understanding
>
> Usually accounts are grouped using headers. At minimum people use:
>
> * Liabilities
> * Assets
> * Equity
> * Retained earnings
> * Result for the year
> * Total Income
> * Total Expense
>
> Usually assets/ liabilities are split into subgroups like Cash/Fixed
> assets/others. In other words: They're an easy way to define the level
> of totals you want.
OK, thanks
Nigel