帝国cms万能标签SQL查询调用两个表里的数据
时间:11-18
作者:
1.不能用*号查询
2.2个查询字段要一模一样
例如:
[ecmsinfo]'select * from (
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,
2.2个查询字段要一模一样
例如:
[ecmsinfo]'select * from (
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,
1.不能用*号查询
2.2个查询字段要一模一样
例如:
[ecmsinfo]'select * from (
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,playtime from [!db.pre!]ecms_movie union
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,playtime from [!db.pre!]ecms_photo
) a order by newstime desc limit 10',32,40,0,24,7,0[/ecmsinfo]
2.2个查询字段要一模一样
例如:
[ecmsinfo]'select * from (
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,playtime from [!db.pre!]ecms_movie union
select id,classid,onclick,userfen,titleurl,title,newstime,titlepic,morepic,feiyong,playtime from [!db.pre!]ecms_photo
) a order by newstime desc limit 10',32,40,0,24,7,0[/ecmsinfo]