Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Panel
bgColor#fff
  1. 代码处理:调整《经营信息变更申请单》审核方法中获取时间戳方式,且按以上分组做去重处理。数据处理:价格历史变更调整其中一个启用状态为0
  2. 数据处理:数据中心和价格历史变更数据处理:
Code Block
languagesql
themeEclipse
linenumberstrue
--去重历史价格信息
update CT_TDS_SaleDCPH set CFIsEnable = 0 where FID in(
    select min(deph.fid)
    from CT_TDS_SaleDCPH deph
    left join CT_TDA_SaleDataCenter c on c.fid = deph.fparentid
    where deph.CFIsEnable = 1
    and deph.fparentid in(
        select s.fid from CT_TDA_SaleDataCenter s
        left join CT_BAS_MarketPlace m on m.fid=s.CFMarketID
        where m.CFMarketNum in ('D-MTMCGZC') --市场编码
        and to_char(C.FBizDate,'yyyy-MM-dd')>='2023-08-08' --业务日期
        and to_char(C.FBizDate,'yyyy-MM-dd')<='2023-08-08'
    )
    group by deph.fparentid,deph.CFMATERIALID,deph.CFTimestamp
    having count(deph.CFMATERIALID) > 1
);
commit;

--去重价格信息分录
delete from CT_TDS_SaleDCPE where fid in (
    select min(dcpe.fid) from CT_TDS_SaleDCPE dcpe
    left join CT_TDA_SaleDataCenter c on c.fid = dcpe.fparentid
    left join CT_BAS_MarketPlace m on m.fid=c.CFMarketID
    where m.CFMarketNum in ('D-MTMCGZC') --市场编码
    and to_char(C.FBizDate,'yyyy-MM-dd')>='2023-08-08' --业务日期
    and to_char(C.FBizDate,'yyyy-MM-dd')<='2023-08-08'
    group by
    dcpe.CFMATERIALID
    having count(dcpe.CFMATERIALID) > 1
)
commit;

相关的文章

Content by Label
showLabelsfalse
max5
spacesYHZSK
showSpacefalse
sortmodified
reversetrue
typepage
cqllabel = "营销管理" and type = "page" and space = "YHZSK"
labels营销管理

...

Page properties
hiddentrue
相关问题