Announcement

Collapse
No announcement yet.

POPULATE_GROUP_WITH_QUERY order by prob

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • POPULATE_GROUP_WITH_QUERY order by prob

    tag zusammen,

    kann mir hier jemand sagen, warum in orace forms ein select-statement in einer variablen, mit welcher ich dann mit POPULATE_GROUP_WITH_QUERY eine record group befülle, nicht mit group by sortierbar ist?! die program unit sieht so aus:

    PROCEDURE populate_price_code_rg IS
    --
    v_tmp NUMBER;
    --
    v_query VARCHAR2(5000) :=
    'select pc.price_code price_code
    ,pc.description description
    ,pl.list_price list_price
    , ph.currency_code currency_code
    from BDS_PRICELIST_LINE pl,
    BDS_PRICELIST_HEAD ph,
    bds_price_code pc
    where pc.suborg_code = nvl('''||:b1.suborg_code||''', sd_app.get_env(''SUBORG_CODE''))
    and pc.price_type = ''S''
    and pc.active = ''Y''
    and pc.company_code = nvl('''||:b1.company_code||''',pc.company_code)
    and pc.company_code IN (SELECT company_code
    FROM bu_company_valid_env_v)
    and ph.suborg_code = pc.suborg_code
    AND pl.suborg_code = ph.suborg_code
    AND pl.pricelist_name = ph.pricelist_name
    AND pl.selection_price_code = pc.price_code
    AND ph.price_Type = ''S'' -- only Sales Pricelists
    AND ph.active = ''Y''
    AND pl.price_eff_qty <= 1
    AND pl.price_eff_date <= sysdate
    AND ph.company_code = pc.company_code
    order by pc.price_code'
    ;
    --
    BEGIN
    --
    v_tmp := POPULATE_GROUP_WITH_QUERY ('B1_SELECTION_PRICE_CODE',v_query);
    --
    END;

    die sortierung wird irgendwie nicht beachte, need help!
Working...
X