数据库(子查询)
where parent_id=0
select shop_price from`kangarooisland_database`.`ki_goods`where cat_id in( select cat_id from`kangarooisland_database`.`ki_category` where parent_id=0) and is_hot=1 order by goods_id desc LIMIT 4
//查询数据库得到热销商品的价格 shop_price
$hot_goods_list = ‘select shop_price from‘. $GLOBALS[‘ecs‘]->table(‘goods‘) .‘where cat_id in( select cat_id from‘
. $GLOBALS[‘ecs‘]->table(‘category‘) .‘ where parent_id=‘.$row[‘cat_id‘].‘) and is_hot=1 order by goods_id desc LIMIT 4‘;
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。