You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by Byron Foster <bf...@base2.cc> on 2001/08/06 21:53:42 UTC
Torque table and column naming
Hello,
I was wondering if it would useful to submit a patch that would
change the behavior of how a table and column name is converted from the
database xml schema to the java source name. Currently the behavior is so:
foo_bar -> FooBar
FooBar -> Foobar
fooBar -> Foobar
However, I thought it would be more intuitive to change the behavior to
this:
foo_bar -> FooBar
FooBar -> FooBar
fooBar -> FooBar
Foobar -> Foobar
foobar -> Foobar
Formally, always capitalize first character. Always capitalize
character after an underscore, remove underscores. Change nothing else.
Java source names created by database names with underscores would not
change under this new approach. But I think the added behavior is more
intuitive. In general it seems to me that if I name a table "FooBar" I
would like the class name to reflect the same, and not "Foobar". Same
goes for the column names. The database xml names are significant since
they may either be converted from database models, or output sql from
torque may be used to create db models.
Is this too much of a drastic change in naming? should this altered
behavior be a property to be turned on?
Thanks,
Byron
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org