I am trying to select a table based on the value of the input in another table. lets say
SELECT tale0.*,class.*,hamburger.*
FROM
CASE tale0.id=1
THEN class
END
CASE tale0.id=2
THEN hamburger
is this the way to go or is there a different method?
No, you can’t use a CASE statement in the FROM clause. You will need to join in both tables, then pull the field from the relevant table based on the value: