Indexing for query using CASE for join
You should probably try with OR like:

select * 
  from myTable join otherTable
on (setting = 'A' and value = column1) or 
   (setting = 'B' and value = column2)


Also UNION ALL may work for you

select * from myTable join otherTable on setting = 'A' and value = column1
union all
select * from myTable join otherTable on setting = 'B' and value = column2