修改库
This commit is contained in:
@@ -12,9 +12,9 @@ if not os.path.exists(path):
|
||||
year_month = int(sys.argv[1]) if len(sys.argv) > 1 else int(dateutils.format_date(datetime.utcnow(), "%Y%m"))
|
||||
log.info(f"测试月份:{year_month}")
|
||||
|
||||
avm_df = pgsql.scan_by_sql_to_data_frame(f"select urbn_id,urbn_nm,gujia_bds_comm_num,gujiabdsvalmnycommnum from t_app_p9pha_plda.avm_evaluation_gj_h where gujia_bds_yrmo={year_month} ")
|
||||
comm_df = pgsql.scan_by_sql_to_data_frame(f"select urbn_id,gujia_admndiv_nm,gujia_comm_id,comm_nm from base.t0831_bigdata_community_gj_h where gujia_bds_bds_st=0 ")
|
||||
price_df = pgsql.scan_by_sql_to_data_frame(f"select gujia_bds_id as gujia_comm_id,gujia_comm_basic_prc from t_app_p9pha_plda.avm_community_base_price_gj_h where gujiabds_clc_yrmo_val={year_month} ")
|
||||
avm_df = pgsql.scan_by_sql_to_data_frame(f"select urbn_id,urbn_nm,gujia_bds_comm_num,gujiabdsvalmnycommnum from price_stat.avm_evaluation_gj_h where gujia_bds_yrmo={year_month} ")
|
||||
comm_df = pgsql.scan_by_sql_to_data_frame(f"select urbn_id,gujia_admndiv_nm,gujia_comm_id,comm_nm from base.bigdata_community where gujia_bds_bds_st=0 ")
|
||||
price_df = pgsql.scan_by_sql_to_data_frame(f"select gujia_bds_id as gujia_comm_id,gujia_comm_basic_prc from price_stat.avm_community_base_price where gujiabds_clc_yrmo_val={year_month} ")
|
||||
comm_df = comm_df.merge(avm_df, on="urbn_id", how="left")
|
||||
comm_df = comm_df.merge(price_df, on="gujia_comm_id", how="left")
|
||||
no_price_comm_df = comm_df[comm_df.gujia_comm_basic_prc.isna()][['urbn_id','urbn_nm','gujia_admndiv_nm','gujia_comm_id','comm_nm']]
|
||||
|
||||
Reference in New Issue
Block a user