db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Manske, Michael" <Michael.Man...@dat.de>
Subject RE: different internal variable names
Date Mon, 04 Aug 2003 07:00:55 GMT
As far as i know torque offers no solution for that issue, you will have to 
change your templates. 
It's one disatvantage of torque that it doesn't provide loose coupling
between
database and java objects. In my opinion it would be better if torque would
use the xml schema at runtime to map java names on table/column names.

regards,
Michael

> -----Original Message-----
> From: Geoff Fortytwo [mailto:g42@ign.com]
> Sent: Friday, August 01, 2003 10:04 PM
> To: Apache Torque Users List
> Subject: different internal variable names
> 
> 
> This topic was talked about on this list recently, but no one 
> seemed to 
> suggest a solution.
> 
> If I have a table column named "short" then that'll screw 
> things up because 
> that's a reserved java keyword, so a variable can't have that name. 
> Assuming that the column name can't be changed (due to lots 
> of other apps 
> already using the table) then is the only solution to modify 
> the velocity 
> code so that, for instance, all internal variables have an underscore 
> appended to them? That solves the problem for all possible 
> java reserved 
> name conflicts.
> 
> But is there a way to fix this without modifying velocity? 
> The javaName 
> column only fixes the names of the functions, it doesn't 
> alter the internal 
> variable names.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message