TD_PROMODST_LVW

(SQL View)
Index Back

List of distrib id's by promo

List of distribution id's by promotion

SELECT DISTINCT A.SETID , A.PPRC_PROMO_CD , B.DST_ID , D.LANGUAGE_CD , D.DESCR , D.DESCRSHORT FROM PS_PPRC_PROMO_TBL A , PS_DST_CODE_TBL B , PS_SET_CNTRL_REC CC , PS_DST_CODE_LG D WHERE A.SETID = CC.SETCNTRLVALUE AND CC.RECNAME = 'DST_CODE_TBL' AND B.SETID = D.SETID AND B.DST_ID = D.DST_ID AND B.EFFDT = D.EFFDT AND CC.SETID = B.SETID AND B.DST_USE = 'DIS' AND B.EFFDT = ( SELECT MAX(B_ED.EFFDT) FROM PS_DST_CODE_TBL B_ED WHERE B.SETID = B_ED.SETID AND B.DST_ID = B_ED.DST_ID AND B_ED.EFFDT <= %CurrentDateIn) AND (EXISTS( SELECT 'X' FROM PS_PPRC_PROMO_TBL C WHERE A.SETID = C.SETID AND A.PPRC_PROMO_CD = C.PPRC_PROMO_CD AND B.DST_ID = C.DST_ID) OR EXISTS( SELECT 'X' FROM PS_TD_PRO_MERC_CUS D WHERE A.SETID = D.SETID AND A.PPRC_PROMO_CD = D.PPRC_PROMO_CD AND B.DST_ID = D.DST_ID))

  • Related Language Record for TD_PROMO_DST_VW
  • # PeopleSoft Field Name PeopleSoft Field Type Database Column Type Description
    1 SETID Character(5) VARCHAR2(5) NOT NULL SetID
    2 PPRC_PROMO_CD Character(20) VARCHAR2(20) NOT NULL Price Promotion Code
    3 DST_ID Character(10) VARCHAR2(10) NOT NULL Distribution Code
    4 LANGUAGE_CD Character(3) VARCHAR2(3) NOT NULL Language Code
    5 DESCR Character(30) VARCHAR2(30) NOT NULL Description
    6 DESCRSHORT Character(10) VARCHAR2(10) NOT NULL Short Description