我正在将统计数据从MySQL切换到亚马逊DynamoDB和弹性MapReduce。我有以下查询,适用于MySQL,我在hive上有相同的表,需要与MySQL上相同的结果( last_week,last_month和last_year的产品视图)。UNIX_TIMESTAMP(CONCAT(DATE_SUB(FROM_UNIXTIME(UNIX_TIMESTAMP()), 31)," ","00:00:00")) GROUP BY product_id;
但我需要分组
我正在用php/MySQL做一个应用程序,我需要每年获取统计数据,按状态分组。create table Archive ( dates (xx-xx-xxxx) )createdate_format(dates,'%Y') as date, count(id) as nbId from archive gro