I need to select many ( around 15 columns) from 4 tables and arrange them in an order ( that i need). Some of these tables have the same column name, and other different one had tried many queries, but of no use. could any one suggest a query??
select t1.col1, t2.col1, t3.col1, t4.col1 ... etc from table1 t1 inner join table2 t2 on t1.col2 = t2.col2 inner join table3 t3 on t1.col3 = t3.col3 inner join table4 t4 on t1.col4 = t4.col4 where ... etc.
If you need to differentiate columns of the same name, just give them aliases such as select t1.col1 AS Myt1Col1, t2.col1 AS Myt2col1... etc