select cl_type,app_version,count(app_version) as count_num from online.bl_hdfs_maidian_updates where partition_date >= "20200222" group by cl_type,app_version
(select device_id from online.ml_device_day_active_status where partition_date = '{today_str}' and active_type in (1,2)) t2