我的表-1有20列,而表-2有15列。这里我想通过用户ID加入两个表格。 我用这个波纹管查询只在mysql中选择特定的列
SELECT * FROM table_checkout_bidpack as t1 inner JOIN table_user_information
as t2 ON t1.user_id=t2.user_id
此查询选择35列,但我需要在第二个表
我知道这项工作列(USER_NAME)选择
select t1.col1,t1.col2,t1.col3,t1.col4,.....,t2.user_name
FROM table_checkout_bidpack as t1 inner JOIN table_user_information
as t2 ON t1.user_id=t2.user_id
这看起来很大任何其他方式做到这一点
所以你想从t1的所有列,但只有t2从user_name? – 2011-02-25 04:56:30