I can't figure out why this subselect doesn't return anything.
select value from mytable where
indx = @var
and f() in (select num from nums);
when this version does:
select value from mytable where
indx = @var
and f() in (2,5,11);
When I create a list identical to the results from the subselect, it works, but when using a subselect doesn't.
Also, this works:
select value from mytable where
indx = @var
and 2 in (select num from nums);