[gold-users] Error in gchproject after adding an object attribute
Mike McCarty
mmccar19 at utk.edu
Mon Feb 1 12:24:12 MST 2010
Hi,
I used the follow commands to add an attribute to our Project object.
goldsh Attribute Create Object=Project Name=DisplayProject DataType=Boolean
DefaultValue=False
Afterwards the project table looked like the following.
gold=> \d g_project
Table "public.g_project"
Column | Type | Modifiers
---------------------+-------------------------+----------------------------
--------
g_creation_time | integer | not null
g_modification_time | integer | not null
g_deleted | character varying(5) | default 'False'::character
varying
g_request_id | integer | not null
g_transaction_id | integer | not null
g_name | character varying(1024) |
g_active | character varying(5) | default 'True'::character
varying
g_organization | character varying(1024) |
g_special | character varying(5) | default 'False'::character
varying
g_description | character varying(1024) |
g_grant_number | character varying(1024) |
g_amie_transaction | integer | default 0
g_amie_active | character varying(5) | default 'False'::character
varying
g_nccs_project_id | character varying(1024) |
g_sent_to_nccs | character varying(5) | default 'False'::character
varying
g_pi | character varying(1024) |
g_prj_type | character varying(1024) |
g_fos | integer |
g_display_project | character varying(5) | default 'False'::character
varying
Indexes:
"g_project_deleted_idx" btree (g_deleted)
"g_project_name_idx" btree (g_name)
"g_project_txnid_idx" btree (g_transaction_id)
Then in the psql...
Set g_display_project to the default for the existing records.
update g_project set g_display_project = 'False';
Set g_display_project to True¹ using the filter I had in my forms project
select query.
update g_project set g_display_project = 'True' where <filtered for specific
projects>
My problem is that I now get this in gchproject.
bash-3.2$ gchproject -p TG-STA100003 -X AmieActive=True
DBD::Pg::db do failed: ERROR: column "g_fos" is of type integer but
expression is of type character varying
HINT: You will need to rewrite or cast the expression.
Notice this was the last column before I added g_display_project. Without
looking at the source code, I would guess that there¹s an update SQL
statement in the database abstraction layer that¹s trying to set a char to
g_fos instead of g_display_project. Is there another data structure that I
need to update after adding the attribute? Or what using psql directly a
bad idea?
Thanks,
-mike
Mike McCarty, HPC Software Developer
National Institute for Computational Sciences (NICS)
University of Tennessee
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.supercluster.org/pipermail/gold-users/attachments/20100201/2e5d4ba2/attachment.html
More information about the gold-users
mailing list