SELECT o.partner_id FROM order o LEFT JOIN partner p on p.id=o.partner_id LEFT JOIN team t on t.id
$sql="SELECTo.partner_idFROMorderoLEFTJOINpartnerponp.id=o.partner_idLEFTJOINteamtont...
$sql="SELECT o.partner_id FROM order o LEFT JOIN partner p on
p.id=o.partner_id LEFT JOIN team t on t.id=o.team_id where
o.state='pay' and o.pay_time >= 1364313600 and (( o.rstate !=
'askrefund' and o.allowrefund = 'Y') or o.allowrefund = 'N') and
o.pay_time <= 1364632869 GROUP BY o.partner_id ORDER BY
sum(t.team_price*o.quantity) DESC"; 有什么错 展开
p.id=o.partner_id LEFT JOIN team t on t.id=o.team_id where
o.state='pay' and o.pay_time >= 1364313600 and (( o.rstate !=
'askrefund' and o.allowrefund = 'Y') or o.allowrefund = 'N') and
o.pay_time <= 1364632869 GROUP BY o.partner_id ORDER BY
sum(t.team_price*o.quantity) DESC"; 有什么错 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询
广告 您可能关注的内容 |