DBA Data[Home] [Help]

APPS.ICX_REQ_ACCT_DIST SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 18

        SELECT  hecv.default_code_combination_id employee_default_account_id,
                msi.expense_account
        FROM    hr_employees_current_v hecv,
                mtl_system_items msi,
                icx_shopping_carts isc,
                icx_shopping_cart_lines iscl
        WHERE   msi.INVENTORY_ITEM_ID (+) = iscl.ITEM_ID
        AND     nvl(msi.ORGANIZATION_ID,
                    nvl(isc.DESTINATION_ORGANIZATION_ID,
                        iscl.DESTINATION_ORGANIZATION_ID)) =
                nvl(isc.DESTINATION_ORGANIZATION_ID,
                    iscl.DESTINATION_ORGANIZATION_ID)
        AND     hecv.EMPLOYEE_ID = v_emp_id
        AND     iscl.cart_id = v_cart_id
        AND     iscl.cart_line_id = v_cart_line_id
        AND     nvl(isc.org_id, -9999) = nvl(v_oo_id, -9999)
        AND     nvl(iscl.org_id, -9999) = nvl(v_oo_id, -9999);
Line: 37

      SELECT CHART_OF_ACCOUNTS_ID
      FROM gl_sets_of_books,
           financials_system_parameters fsp
      WHERE gl_sets_of_books.SET_OF_BOOKS_ID = fsp.set_of_books_id;
Line: 669

            IF ak_query_pkg.g_items_table(i).update_flag = 'Y' THEN
		 IF ak_query_pkg.g_items_table(i).attribute_code = 'ICX_PERCENTAGE'  THEN
                    IF v_display_first = ak_query_pkg.g_items_table(i).attribute_code THEN
                       htp.tableData(cvalue => '', crowspan => 1);
Line: 769

            END IF; /* update_flag = 'Y' */
Line: 853

            IF ak_query_pkg.g_items_table(i).update_flag = 'Y' THEN
		 if ak_query_pkg.g_items_table(i).attribute_code = 'ICX_PERCENTAGE'  then
                    if v_display_first = ak_query_pkg.g_items_table(i).attribute_code then
                       htp.tableData(cvalue => '', crowspan => 1);
Line: 948

            END IF; /* update_flag = 'Y' */
Line: 973

            IF ak_query_pkg.g_items_table(i).update_flag = 'Y' THEN
		 if ak_query_pkg.g_items_table(i).attribute_code = 'ICX_PERCENTAGE'  then

                    if v_display_first = ak_query_pkg.g_items_table(i).attribute_code then


                       htp.tableData(cvalue => '', crowspan => 1);
Line: 1092

            END IF; /* update_flag = 'Y' */
Line: 1393

      SELECT COUNT(distribution_num)
      FROM  icx_req_cart_errors
      WHERE cart_id = l_cart_id
      AND   cart_line_id = l_cart_line_id
      AND   distribution_num IS NOT NULL;
Line: 1724

        select  ltrim(rtrim(a.ATTRIBUTE_CODE)) ATTRIBUTE_NAME
        from       ak_region_items a,
        ak_attributes b,
        ak_regions c,
        ak_object_attributes d
        where      a.NODE_DISPLAY_FLAG = 'Y'
        and        a.ATTRIBUTE_CODE = b.ATTRIBUTE_CODE
        and        a.ATTRIBUTE_APPLICATION_ID = b.ATTRIBUTE_APPLICATION_ID
        and        b.DATA_TYPE = 'VARCHAR2'
        and        c.REGION_APPLICATION_ID = 601
        and        a.REGION_CODE = c.REGION_CODE
        and        a.REGION_APPLICATION_ID = c.REGION_APPLICATION_ID
        and        c.DATABASE_OBJECT_NAME = d.DATABASE_OBJECT_NAME
        and        a.ATTRIBUTE_CODE = d.ATTRIBUTE_CODE
        and        a.region_code = 'ICX_CART_LINE_DISTRIBUTIONS_R'
        and        a.ATTRIBUTE_CODE LIKE 'ICX_CHARGE_ACCT_SEG%'
        order by a.display_sequence;
Line: 1743

        select  1
        from       ak_region_items a,
        ak_attributes b,
        ak_regions c,
        ak_object_attributes d
        where      a.NODE_DISPLAY_FLAG = 'Y'
        and        a.ATTRIBUTE_CODE = b.ATTRIBUTE_CODE
        and        a.ATTRIBUTE_APPLICATION_ID = b.ATTRIBUTE_APPLICATION_ID
        and        b.DATA_TYPE = 'VARCHAR2'
        and        c.REGION_APPLICATION_ID = 601
        and        a.REGION_CODE = c.REGION_CODE
        and        a.REGION_APPLICATION_ID = c.REGION_APPLICATION_ID
        and        c.DATABASE_OBJECT_NAME = d.DATABASE_OBJECT_NAME
        and        a.ATTRIBUTE_CODE = d.ATTRIBUTE_CODE
        and        a.region_code = 'ICX_CART_LINE_DISTRIBUTIONS_R'
        and        a.attribute_code = 'ICX_CHARGE_ACCOUNT_NUM';
Line: 1784

     DELETE FROM icx_req_cart_errors
     WHERE cart_id = v_cart_id
     AND   cart_line_id = v_cart_line_id
     AND   distribution_num IS NOT NULL;
Line: 1791

    Delete all the distributions in the table. This need to be done to
    take care of the deletion option. As we don't provide delete button option
    the user will either enter '0' (zero) or leave blank in the percentage
    column to indicate that, account entry is deleted.
    */

    DELETE FROM icx_cart_line_distributions
    WHERE cart_id = v_cart_id
    AND   cart_line_id = v_cart_line_id;
Line: 1899

        icx_req_acct2.update_account( v_cart_line_id => v_cart_line_id,
                                v_oo_id => v_org_id,
                                v_cart_id => v_cart_id,
                                v_segments => v_segment_value,
                                v_allocation_type => v_allocation_type,
                                v_allocation_value => to_number(icx_percentage(i)));
Line: 1915

        icx_req_acct2.update_account_num( v_cart_line_id => v_cart_line_id,
                                v_oo_id => v_org_id,
                                v_cart_id => v_cart_id,
                                v_account_num => icx_charge_account_num(i),
                                v_allocation_type => v_allocation_type,
                                v_allocation_value => to_number(icx_percentage(i)));
Line: 1960

        SELECT  ltrim(rtrim(a.ATTRIBUTE_CODE)) ATTRIBUTE_NAME,
                a.UPDATE_FLAG  UPDATE_FLAG
        FROM       ak_region_items a,
        ak_attributes b,
        ak_regions c
        WHERE      a.NODE_DISPLAY_FLAG = 'Y'
        AND        a.ATTRIBUTE_CODE = b.ATTRIBUTE_CODE
        AND        a.ATTRIBUTE_APPLICATION_ID = b.ATTRIBUTE_APPLICATION_ID
        AND        b.DATA_TYPE = 'VARCHAR2'
        AND        c.REGION_APPLICATION_ID = 601
        AND        a.REGION_CODE = c.REGION_CODE
        AND        a.REGION_APPLICATION_ID = c.REGION_APPLICATION_ID
        AND        a.REGION_CODE = 'ICX_CART_LINE_DISTRIBUTIONS_R'
        AND        a.ATTRIBUTE_CODE LIKE 'ICX_CHARGE_ACCT_SEG%'
        ORDER BY a.display_sequence;
Line: 1978

        SELECT cart_line_id
        FROM icx_shopping_cart_lines
        WHERE cart_id = v_cart_id
        AND   cart_line_id <> v_cart_line_id;
Line: 1984

        SELECT distribution_id
        FROM icx_cart_line_distributions
        WHERE cart_id = v_cart_id
        AND   cart_line_id = v_cart_line_id;
Line: 1990

        SELECT charge_account_num, allocation_value, allocation_type
        FROM icx_cart_line_distributions
        WHERE cart_id = v_cart_id
        AND   cart_line_id = v_cart_line_id;
Line: 1996

        SELECT  1
        FROM       ak_region_items a,
        ak_attributes b,
        ak_regions c,
        ak_object_attributes d
        WHERE      a.NODE_DISPLAY_FLAG = 'Y'
        AND        a.ATTRIBUTE_CODE = b.ATTRIBUTE_CODE
        AND        a.ATTRIBUTE_APPLICATION_ID = b.ATTRIBUTE_APPLICATION_ID
        AND        b.DATA_TYPE = 'VARCHAR2'
        AND        c.REGION_APPLICATION_ID = 601
        AND        a.REGION_CODE = c.REGION_CODE
        AND        a.REGION_APPLICATION_ID = c.REGION_APPLICATION_ID
        AND        c.DATABASE_OBJECT_NAME = d.DATABASE_OBJECT_NAME
        AND        a.ATTRIBUTE_CODE = d.ATTRIBUTE_CODE
        AND        a.region_code = 'ICX_CART_LINE_DISTRIBUTIONS_R'
        AND        a.attribute_code = 'ICX_CHARGE_ACCOUNT_NUM';
Line: 2038

    DELETE FROM icx_cart_line_distributions
    WHERE cart_id = v_cart_id
    AND   cart_line_id <> v_cart_line_id;
Line: 2045

    segments with the actual segment value later. The update flag is updated
    Y in the pl/sql table record to indicate whether the default account need to
    be inherited from the line default.
    */
    l := 1;
Line: 2052

      v_ak_segments(l).update_flag  := ak_col.update_flag;
Line: 2112

             IF v_ak_segments(l).update_flag = 'Y' THEN
                v_line_segments(l) := v_segment_value(l);
Line: 2137

           icx_req_acct2.update_account( v_cart_line_id => req_line.cart_line_id,
                                         v_oo_id => v_org_id,
                                         v_cart_id => v_cart_id,
                                         v_segments => v_line_segments,
                                         v_allocation_type => v_allocation_type,
                                         v_allocation_value => v_allocation_value,
                                         v_validate_flag => 'N');
Line: 2147

               updateability of the segments, we are going to copy over the
               current distribution's segments to all the lines.
           **/
           l := 1;
Line: 2157

           /** Insert the distribution **/
           icx_req_acct2.update_account( v_cart_line_id => req_line.cart_line_id,
                                         v_oo_id => v_org_id,
                                         v_cart_id => v_cart_id,
                                         v_segments => v_line_segments,
                                         v_allocation_type => v_allocation_type,
                                         v_allocation_value => v_allocation_value,
                                         v_validate_flag => 'N');
Line: 2177

          icx_req_acct2.update_account_num(v_cart_line_id => req_line.cart_line_id,
                                  v_oo_id => v_org_id,
                                  v_cart_id => v_cart_id,
                                  v_account_num => prec.charge_account_num,
                                  v_allocation_type => prec.allocation_type,
                                  v_allocation_value => prec.allocation_value,
                                  v_validate_flag => 'N');
Line: 2202

  SELECT error_text
  FROM icx_req_cart_errors
  WHERE cart_id = v_cart_id
  AND   cart_line_id = v_cart_line_id
  AND distribution_num IS NOT NULL;