|
As [christian.beikov] and [garethdanielsmith] point out the difficulty here is really not even on the coding side. The problem is more in defining what should happen, and that really what should happen is probably different based on where it occurs in the query and its context.
First, we'd need to identify specific cases. This case discusses IN-predicates. We can limit the discussion here to just that. In that context, I agree that empty/null parameter passed into ... in ? ... or ... in should be handled the same as a literal-empty list (... in ()...). Ultimately I'd think that resolves to the following at the SQL level: ... in (null)... as I do not think there are databases that do not accept that; and if there are then let us know and we can conditionally render as ... in () ... for those.
|