Thinkphp 统计数据库字段总值

统计表中字段数据总值:

$startInfo = $objOrderInfo->field("COUNT(*)  number,SUM(order_amount)  account")->where("ctime >='$startPeriod[startTime]' AND ctime <='$startPeriod[endTime]' AND extension_code ='integral'")->find();

posted @ 2014-10-08 11:14  唐扬平  阅读(876)  评论(0)    收藏  举报