标签:item last show 分享 com sele creat origin recycle
一条线是item,para_value,feature;另外一条是 item,sku。
思考过程:先把item和sku表联合查出结果集,然后再把这个结果集当成一张表,最后与另外两张表结合查询。
select *
from (select min(es.sku_price) sku_price, ei.*
from eb_item ei, eb_sku es
where ei.item_id = es.item_id
and ei.audit_status = 1
and ei.show_status = 0
group by ei.ITEM_ID,
ei.ITEM_NAME,
ei.ITEM_NO,
ei.BRAND_ID,
ei.CAT_ID,
ei.TAG_IMG_ID,
ei.TAG_IMG,
ei.IS_NEW,
ei.IS_GOOD,
ei.IS_HOT,
ei.PROMOTION,
ei.AUDIT_STATUS,
ei.SHOW_STATUS,
ei.IMGS,
ei.KEYWORDS,
ei.PAGE_DESC,
ei.ITEM_RECYCLE,
ei.ON_SALE_TIME,
ei.CHECK_TIME,
ei.UPDATE_TIME,
ei.UPDATE_USER_ID,
ei.CREATE_TIME,
ei.CHECKER_USER_ID,
ei.FULL_PATH_DEPLOY,
ei.FULL_PATH_DEPLOY_OFFER,
ei.ORIGINAL_ITEM_ID,
ei.LAST_STATUS,
ei.MERCHANT_ID,
ei.ITEM_SORT,
ei.SALES,
ei.CREATE_USER_ID,
ei.SIM_LEVEL,
ei.GIFT_DESC,
ei.GIFT_IMG,
ei.GIFT_SHOW_TYPE,
ei.IMG_SIZE1) e1,
eb_para_value ev,
eb_feature ef
where e1.item_id = ev.item_id
and ev.feature_id = ef.feature_id
and ef.is_select = 1
标签:item last show 分享 com sele creat origin recycle
原文地址:https://www.cnblogs.com/Each-Person-Got-a-Dream/p/9250006.html