One solution is not to use the switch and keep the lookup to perform the select with a case (if possible) or use a stored procedure if the switch and lookup are on teh database it is possible