Does mysql got cover IF ELSE to select the table dynamically ?
The link here show's IF THEN is for the value, but how can the IF THEN / IF ELSE can achieve to select the table like below :
For example the dynamic table is 'othertable'
SELECT t1.etc,t2.etc,othertable.etc
FROM table1 AS t1,table2 AS t2, IF(t1.value=3,table3,table4) AS othertable
WHERE othertable.table1_id = t1.id