If you look at the vm files, you can see that the column names are
converted to upper case. So the easiest way would be modifying vm files
(MapBuilder.vm, Object.vm, Peer.vm etc.) and take out toUpperCase and
regenerate the java files. I haven't tried that and not sure if that
will cause other problems. Good luck.
Howard
> -----Original Message-----
> From: Patrick Tonidandel [mailto:[EMAIL PROTECTED]]
> Sent: Friday, August 31, 2001 5:44 AM
> To: Turbine-User
> Subject: Troubles with Torque OM Class Generation
>
>
> Hi there,
>
> I have problems with the "Table"MapBuilder.java files
> generated by Torque.
> There are some Databases that have case sensitive behaviour
> on column names
> in select statements.
>
> If I write a application-shema.xml file like :
>
> <database>
> <table name="District" javaName="District" skipSql="true">
> <column name="DistrictID" required="true" primaryKey="true"
> type="INTEGER"/>
> <column name="Description" size="50" type="VARCHAR"/>
> </table>
> </database>
>
> I get a table District on my Sybase ASE DB with the columns
> in the right
> manner : DistrictID and Description.
>
> But the DistrictMapBuilder.java contains only uppercase column names :
>
> public class DistrictMapBuilder implements MapBuilder
> {
> /** the name of this class */
> public static final String CLASS_NAME =
> "com.wuerth.phoenix.speedyadm.om.map.DistrictMapBuilder";
>
> /** item */
> public static String getTable( )
> {
> return "DISTRICT";
> }
>
>
> /** DISTRICT.DISTRICTID */
> public static String getDistrict_Districtid()
> {
> return getTable() + ".DISTRICTID";
> }
>
> /** DISTRICT.DESCRIPTION */
> public static String getDistrict_Description()
> {
> return getTable() + ".DESCRIPTION";
> }
>
> /** the database map */
> private DatabaseMap dbMap = null;
>
> /**
> tells us if this DatabaseMapBuilder is built so that
> we don't have
> to re-build it every time
> */
> public boolean isBuilt()
> {
> if ( dbMap != null )
> return true;
> return false;
> }
>
> /** gets the databasemap this map builder built. */
> public DatabaseMap getDatabaseMap()
> {
> return this.dbMap;
> }
> /** the doBuild() method builds the DatabaseMap */
> public void doBuild ( ) throws Exception
> {
> dbMap = TurbineDB.getDatabaseMap("default");
>
> dbMap.addTable(getTable());
> TableMap tMap = dbMap.getTable(getTable());
>
> tMap.setPrimaryKeyMethod(TableMap.NONE);
>
>
>
> tMap.addPrimaryKey ( getDistrict_Districtid(), new
> Integer(0) );
>
> tMap.addColumn ( getDistrict_Description(), new
> String() );
>
> }
>
> }
>
> In this way I cannot acces my case sensitive DB.
>
> Any help is very appreciated.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]