You can use a view if all the objects returned are scalars not lobs. In this case if you returned the first 4000 characters of the LOB that should work as the documentation indicates that using a function that creates a temporary lob on the source is allowed as long as the result that is returned is not a LOB.
The documentation for 12 is here. It does not ...
COALESCE(IntMin, DecMin, DatMin) ValMin,
COALESCE(IntMax, DecMax, DatMax) ValMax,
COALESCE(IntValue, DecValue, DatValue) ValValue,
COALESCE(IntRequired, DecRequired, DatRequired) ValRerquired
But it seems you must to convert all separate values to the same datatype (...
You shouldn't allow arbitrary queries for these filters. This opens the door to a world of pain, since arbitrary queries can take arbitrarily long and cause arbitrary mischief.
Rather, you should plan for certain types of filters that correspond to pre-defined queries, perhaps with some parameters that can be chosen by the user and are stored in a table.
Since there are already good answers to the question I will focus on the DRY-aspect (DRY = don't repeat yourself).
I got used to use CROSS APPLY, if I have to do the same calculations in the same query multiple times (don't forget GROUP BY / WHERE / ORDER BY, where the same calcualtions tend to occure again and again and again).