Using bit in primary key not supported?
Martin Tilsted <[email protected]> Fri, 08 Oct 2010 04:59:45 +0200
| Newsgroups | gmane.comp.jakarta.turbine.torque.user |
|---|---|
| Message-ID | <[email protected]> |
In my schema.xml file I have <table name="templatevalue" idMethod="native"> <column name="name" primaryKey="true" required="true" size="255" type="VARCHAR"/> <column default="true" name="preview" primaryKey="true" required="true" type="BIT"/> <!-- Other fields removed --> </table> But it seems like torque is unable to handle a primary key with a bit field, because it generate the file BaseTemplatevalue.java with the function public ObjectKey getPrimaryKey() which contain the line pks[1] = SimpleKey.keyFor(getPreview()); But eclipse complains that there is no SimpleKey.keyFor which take a boolean argument. So am I doing something wrong, or is this just not supported. This is using torque 3.3 with postgresql 8.4. It's easy to work-around using an int, but I would like to keep it boolean, because it is a boolean :} Martin