Using the latest snapshot from Jenkins, I get this upgrading from 2.0.6 to 2.1
* ERROR 13:35:46,079 ERROR: column dataelemen1_.uuid does not exist
Position: 166 (JDBCExceptionReporter.java [Thread-2])
Since we want to use a more stable id for external communication, I think I added uuid to dataelement (at least I've added the population of uuids on startup).
I think that means you have to have
hibernate.hbm2ddl.auto = update
set on the first startup for Hibernate to take care of adding it. I think this is our "default" way of handling db changes, but we should probably be more explicit about it..
2) Here is the query produced by Hibernate, which fails from the postgres log.
DETAIL: parameters: $1 = 'default'
ERROR: column dataelemen1_.uuid does not exist at character 166
STATEMENT: select optioncomb0_.categorycomboid as category2_149_1_,
optioncomb0_.categoryoptioncomboid as category1_1_,
dataelemen1_.categoryoptioncomboid as category1_143_0_,
dataelemen1_.uuid as uuid143_0_, dataelemen1_1_.categorycomboid as
category2_144_0_ from categorycombos_optioncombos optioncomb0_ inner
join categoryoptioncombo dataelemen1_ on
optioncomb0_.categoryoptioncomboid=dataelemen1_.categoryoptioncomboid
left outer join categorycombos_optioncombos dataelemen1_1_ on
dataelemen1_.categoryoptioncomboid=dataelemen1_1_.categoryoptioncomboid
where optioncomb0_.categorycomboid=$1
ERROR: current transaction is aborted, commands ignored until end of
transaction block
Look carefully and you will see that the dataelement1_ table
references categoryoptioncombo, which according to the query, needs a
uuid.
3) dataelement already has a uuid column.
Regards,
Jason
···
On Wed, Mar 2, 2011 at 2:54 PM, Jo Størset <storset@gmail.com> wrote:
Hi,
Den 2. mars 2011 kl. 18.08 skrev Jason Pickering:
Using the latest snapshot from Jenkins, I get this upgrading from 2.0.6 to 2.1
* ERROR 13:35:46,079 ERROR: column dataelemen1_.uuid does not exist
Position: 166 (JDBCExceptionReporter.java [Thread-2])
Since we want to use a more stable id for external communication, I think I added uuid to dataelement (at least I've added the population of uuids on startup).
I think that means you have to have
hibernate.hbm2ddl.auto = update
set on the first startup for Hibernate to take care of adding it. I think this is our "default" way of handling db changes, but we should probably be more explicit about it..
Jo
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260974901293
2) Here is the query produced by Hibernate, which fails from the postgres log.
DETAIL: parameters: $1 = 'default'
ERROR: column dataelemen1_.uuid does not exist at character 166
STATEMENT: select optioncomb0_.categorycomboid as category2_149_1_,
optioncomb0_.categoryoptioncomboid as category1_1_,
dataelemen1_.categoryoptioncomboid as category1_143_0_,
dataelemen1_.uuid as uuid143_0_, dataelemen1_1_.categorycomboid as
category2_144_0_ from categorycombos_optioncombos optioncomb0_ inner
join categoryoptioncombo dataelemen1_ on
optioncomb0_.categoryoptioncomboid=dataelemen1_.categoryoptioncomboid
left outer join categorycombos_optioncombos dataelemen1_1_ on
dataelemen1_.categoryoptioncomboid=dataelemen1_1_.categoryoptioncomboid
where optioncomb0_.categorycomboid=$1
ERROR: current transaction is aborted, commands ignored until end of
transaction block
Look carefully and you will see that the dataelement1_ table
references categoryoptioncombo, which according to the query, needs a
uuid.
3) dataelement already has a uuid column.
Regards,
Jason
On Wed, Mar 2, 2011 at 2:54 PM, Jo Størset <storset@gmail.com> wrote:
Hi,
Den 2. mars 2011 kl. 18.08 skrev Jason Pickering:
Using the latest snapshot from Jenkins, I get this upgrading from 2.0.6 to 2.1
* ERROR 13:35:46,079 ERROR: column dataelemen1_.uuid does not exist
Position: 166 (JDBCExceptionReporter.java [Thread-2])
Since we want to use a more stable id for external communication, I think I added uuid to dataelement (at least I've added the population of uuids on startup).
I think that means you have to have
hibernate.hbm2ddl.auto = update
set on the first startup for Hibernate to take care of adding it. I think this is our "default" way of handling db changes, but we should probably be more explicit about it..
Jo
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260974901293
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260974901293
This sounds about right. I guess I only added uuids that are missing for data elements, while optioncombo has also gotten uuid added in the hibernate mapping (it already had uuid as a property). I thought hibernate would take care of updating by itself, and have not noticed any trouble myself (on quite a lot of databases). But I'm not the most knowledgable about hibernate, so there might be subtle details I don't know about.
This uuid is not critical for now (as long as nobody needs to post datavalues with combos to the api), so it can be removed from the branch if finding another solution is difficult.
Jo
···
Den 2. mars 2011 kl. 19.33 skrev Jason Pickering:
Thanks for this Jo, but I think this is not the issue. A bit more detail.
-----Original Message-----
From: Jo Størset <storset@gmail.com>
Sender: dhis2-devs-bounces+greg.rowles=gmail.com@lists.launchpad.net
Date: Wed, 2 Mar 2011 20:00:40
To: Jason Pickering<jason.p.pickering@gmail.com>
Cc: dhis2-devs<dhis2-devs@lists.launchpad.net>
Subject: Re: [Dhis2-devs] Trouble upgrading to 2.1
Den 2. mars 2011 kl. 19.33 skrev Jason Pickering:
Thanks for this Jo, but I think this is not the issue. A bit more detail.
<snip/>
This sounds about right. I guess I only added uuids that are missing for data elements, while optioncombo has also gotten uuid added in the hibernate mapping (it already had uuid as a property). I thought hibernate would take care of updating by itself, and have not noticed any trouble myself (on quite a lot of databases). But I'm not the most knowledgable about hibernate, so there might be subtle details I don't know about.
This uuid is not critical for now (as long as nobody needs to post datavalues with combos to the api), so it can be removed from the branch if finding another solution is difficult.
OK. Not really sure what to do at this point then. I have tried the
procedure several times. My categoryoptioncombo table is defined as
follows
CREATE TABLE categoryoptioncombo
(
categoryoptioncomboid integer NOT NULL,
CONSTRAINT categoryoptioncombo_pkey PRIMARY KEY (categoryoptioncomboid)
)
WITH (
OIDS=FALSE
);
Does not seem to have a uuid property. Is this the right table?
···
On Wed, Mar 2, 2011 at 3:30 PM, Jo Størset <storset@gmail.com> wrote:
Den 2. mars 2011 kl. 19.33 skrev Jason Pickering:
Thanks for this Jo, but I think this is not the issue. A bit more detail.
<snip/>
This sounds about right. I guess I only added uuids that are missing for data elements, while optioncombo has also gotten uuid added in the hibernate mapping (it already had uuid as a property). I thought hibernate would take care of updating by itself, and have not noticed any trouble myself (on quite a lot of databases). But I'm not the most knowledgable about hibernate, so there might be subtle details I don't know about.
This uuid is not critical for now (as long as nobody needs to post datavalues with combos to the api), so it can be removed from the branch if finding another solution is difficult.
Jo
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260974901293
Thanks for this Jo, but I think this is not the issue. A bit more detail.
This sounds about right. I guess I only added uuids that are missing for data elements, while optioncombo has also gotten uuid added in the hibernate mapping (it already had uuid as a property). I thought hibernate would take care of updating by itself, and have not noticed any trouble myself (on quite a lot of databases). But I’m not the most knowledgable about hibernate, so there might be subtle details I don’t know about.
This uuid is not critical for now (as long as nobody needs to post datavalues with combos to the api), so it can be removed from the branch if finding another solution is difficult.
Yeah, I am beginning to think it is a permissions issue...again....
···
On Wed, Mar 2, 2011 at 3:49 PM, Lars Helge Øverland <larshelge@gmail.com> wrote:
Works here.. Permissions? Try adding a "uuid" column manually (like the one
we have for dataelement etc) as a quick fix.
On Wed, Mar 2, 2011 at 3:45 PM, Jason Pickering > <jason.p.pickering@gmail.com> wrote:
OK. Not really sure what to do at this point then. I have tried the
procedure several times. My categoryoptioncombo table is defined as
follows
CREATE TABLE categoryoptioncombo
(
categoryoptioncomboid integer NOT NULL,
CONSTRAINT categoryoptioncombo_pkey PRIMARY KEY (categoryoptioncomboid)
)
WITH (
OIDS=FALSE
);
Does not seem to have a uuid property. Is this the right table?
On Wed, Mar 2, 2011 at 3:30 PM, Jo Størset <storset@gmail.com> wrote:
>
> Den 2. mars 2011 kl. 19.33 skrev Jason Pickering:
>
>> Thanks for this Jo, but I think this is not the issue. A bit more
>> detail.
>
>
> <snip/>
>
> This sounds about right. I guess I only added uuids that are missing for
> data elements, while optioncombo has also gotten uuid added in the hibernate
> mapping (it already had uuid as a property). I thought hibernate would take
> care of updating by itself, and have not noticed any trouble myself (on
> quite a lot of databases). But I'm not the most knowledgable about
> hibernate, so there might be subtle details I don't know about.
>
> This uuid is not critical for now (as long as nobody needs to post
> datavalues with combos to the api), so it can be removed from the branch if
> finding another solution is difficult.
>
> Jo
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260974901293