If you are unioning two indexes, you ipso facto need a join between the results of the two indexes. In other words: lookup index on
a
for matches, lookup index
b
, and join the results to get a final result for a
where
on
a
and
b
. Single column indexes are rarely useful because it's quite rare to be querying just a single column in a table, with no other columns selected. Obviously there are
certain cases when this might happen, but I would question it at first glance. —
Charlieface 1 min ago