hi tom,
would you also allow expressions that use more than one field-descriptor ?
<field-descriptor name="curDate" jdbc-type="TIMESTAMP" column="TEST" read-expression="$FirstName || ' ' || $LastName" ...
i assume that these columns are of the same class-descriptor. i think we should not provide the full flexibility (relationships etc) in these expressions.
jakob
Thomas Dudziak schrieb:
I was thinking about what the Oracle experts that I know, always have to do. Every once in a while they have a char column in the database that actually contains a date (don't ask me why). In order to work with it they always have to use something like TO_DATE in a SELECT, and TO_CHAR (I believe that's what it is called, I'm no Oracle expert myself) in an INSERT or UPDATE. I wonder whether it would be possible to support this ? E.g.
<field-descriptor name="curDate" jdbc-type="TIMESTAMP" column="CUR_DATE" read-expression="TO_DATE($curDate)" write-expression="TO_STRING($curDate)">
where OJB would expand the $curDate spec to the (possibly aliased column name). And if no column has been specified, then the expressions both specify constant expressions (though they can be different). Would that be difficult to support ?
Tom
--------------------------------------------------------------------- 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]