Hello,
Thanks for your quick reply. But this is not what I meant. I'm generating the hbm files dynamically. So I do not know what the user wants to filter.
Let's say we have a <many-to-one> with Items. An item looks like String property1; int property2; DateTime property3; ...
Sometimes the user wants to filter on property1 == "Name"; Sometimes the user wants to filter on property1 LIKE "Na%"; Sometimes the user wants to filter on property2 == 1; Sometimes the user wants to filter on property2 > 1;
So the filtering is dynamic.
The only solution for me is to provide filters for EVERY type and EVERY property:
<filter name="stringEqFilter" condition = ":par = Title" /> <filter name="stringGtFilter" condition = ":par > a /> ... <filter name="intEqFilter" condition = ":par = 1" /> <filter name="intGtFilter" condition = ":par > 1" /> ...
So this is a little bit overkill.
Is there a way to do this differently. Something like:
<filter name="stringFilter" condition= ":par" /> where the :par parameter can be filled in dynamically. Like :par equal to "Title = MacGyver" But that doensn't work
Regards,
|