portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Custine <chris.cust...@gmail.com>
Subject Postgres problems with Torque Generator (BIT type)
Date Sun, 14 Nov 2004 16:26:24 GMT
Is anyone aware of the problems with using the BIT type with Torque
Gen when targetting Postgres as the DB?  I have noticed the addition
of a bunch of BIT types in the security tables and some of the prefs
tables and they are really a pain to work around if you use Postgres.

I don't know what the correct solution is, but a Torque Gen BIT type
maps to a boolean in Postgres, which does not allow 0 or 1 as values
which is what the sql scripts have.  My initial solution was to change
the 0 and 1 values in the sql scripts into true or false and that
worked for a while until some of the recent updates to security.  The
best fix I have right now is to edit the db.props file within the
torque-gen jar file and map BIT=int2.  This works except in
populate-userinfo-for-default-psml.sql the inserts into
PREFS_PROPERTY_VALUE are using the boolean true and false syntax
instead of 0 or 1 like everything else using BIT.

Obviously this is a bigger issue than Jetspeed but I have no earthly
idea if anything in Torque is going to resolve this.  Would it be
possible to get a resolution here and at least fix resolve it within
Jetspeed?  I think the choices are:
* Use a different type in Torque that works across all the DBs 
* Provide a patched Torque gen jar in the  Jetspeed specific
repository with the BIT type mapped to int2 and agree to always use
the 0 or 1 values for these columns instead of true/false

If anyone else is using Postgres and I am missing something please let
me know, this is a real pain in the ass  :-)


To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org

View raw message