On Apr 25, 2010, at 5:17 PM, Andrew Lindesay wrote:
> Hi Andrus;
>
>>> I would rather not have free-form query strings in my code; I
>>> prefer compiling against the Cayenne query-assembly objects.
>> Yeah, that's a somewhat unfortunate situation, as there are plans
>> for SelectQuery-like API for EJBQL in 3.1, but the old API for
>> specifying columns is gone already.
>
> Is it easy/hard/impossible to plumb back in again? :)
Not impossible, but is indeed rather involved and I don't see much
point doing it. Encapsulating the String parts of the EJBQL-based
select in some helper class is probably easier. After all this is not
SQL and the path parts are based on the object properties whose names
are auto-generated for the entity classes, and the rest can be
parameterized and encapsulated. Expression.toEJBQL(..) method should
help too (although it probably has a few remaining holes when used
with non-"primitive" parameters).
>>> Do you think this would be a tricky thing for me to safely
>>> implement in the 3.0-TRUNK?
>> What do you mean by 3.0-TRUNK?
>
> I mean for use with 3.0.1 where you applied my other two patches
> earlier this month.
I see. Here is this branch location:
https://svn.apache.org/repos/asf/cayenne/main/branches/STABLE-3.0/
Andrus
This archive was generated by hypermail 2.0.0 : Sun Apr 25 2010 - 05:33:53 EDT