DBA Data[Home] [Help]

APPS.ECE_ADVO_ADVICE_PKG SQL Statements

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

Line: 44

       SELECT   text
       FROM     ece_output
       WHERE    run_id = p_run_id
       ORDER BY line_id;
Line: 80

      SELECT   ece_output_runs_s.NEXTVAL
      INTO     p_run_id
      FROM     sys.dual;
Line: 134

    **  Open the cursor to select the actual file output from ece_output.
    **
    */

    xProgress := 'ADVO-10-1060';
Line: 181

    **  Assume everything went ok so delete the records from ece_output.
    **
    */

    xProgress := 'ADVO-10-1090';
Line: 189

    DELETE
    FROM     ece_output
    WHERE    run_id = p_run_id;
Line: 197

                    'ECE_NO_ROW_DELETED',
                    'PROGRESS_LEVEL',
                    xProgress,
                    'TABLE_NAME',
                    'ECE_OUTPUT' );
Line: 373

    cHeader_select           VARCHAR2(32000);
Line: 374

    cLine_select             VARCHAR2(32000);
Line: 460

    **  The 'select_clause' procedure will build the SELECT, FROM and WHERE
    **  clauses in preparation for the dynamic SQL call using the EDI data
    **  dictionary for the build.  Any necessary customizations to these
    **  clauses need to be made *after* the clause is built, but *before*
    **  the SQL call.
    **
    */

     xProgress := 'ADVOB-10-1040';
Line: 469

     ece_extract_utils_pub.select_clause ( cTransaction_Type,
                                           cCommunication_Method,
                                           cHeader_Interface,
                                           l_header_tbl,
                                           cHeader_select,
                                           cHeader_from,
                                           cHeader_where );
Line: 479

     ece_extract_utils_pub.select_clause ( cTransaction_Type,
                                           cCommunication_Method,
                                           cLine_Interface,
                                           l_line_tbl,
                                           cLine_select,
                                           cLine_from,
                                           cLine_where );
Line: 611

    **  Build the complete SELECT statement for each level.
    **
    */

    xProgress      := 'ADVOB-10-1180';
Line: 616

    cHeader_select := cHeader_select                                ||
                      cHeader_from                                  ||
                      cHeader_where;
Line: 619

    ec_debug.pl ( 3, 'cHeader_select: ',cHeader_select );
Line: 622

    cLine_select   := cLine_select                                  ||
                      cLine_from                                    ||
                      cLine_where;
Line: 625

    ec_debug.pl ( 3, 'cLine_select: ',cLine_select );
Line: 629

    **  Open a cursor for each of the SELECT calls.  This tells the
    **  database to reserve space for the data returned by the SELECT
    **  statement.
    **
    */

    xProgress    := 'ADVOB-10-1200';
Line: 643

    **  Parse each SELECT statement so the database understands the
    **  command.  If the parse fails, trap and print the point of
    **  failure and exit the procedure with an error.
    **
    */

    xProgress := 'ADVOB-10-1220';
Line: 652

                       cHeader_select,
                       dbms_sql.native );
Line: 657

                                                   cHeader_select );
Line: 664

                       cLine_select,
                       dbms_sql.native );
Line: 669

                                                   cLine_select );
Line: 689

    **  Define the data type for every column in each SELECT statement
    **  so the database understands how to populate it.
    **
    */

    xProgress := 'ADVOB-10-1260';
Line: 699

                               cHeader_select,
                               ece_extract_utils_PUB.G_MaxColWidth );
Line: 708

                               cLine_select,
                               ece_extract_utils_PUB.G_MaxColWidth );
Line: 822

    **  Execute the Header level SELECT statement.
    **
    */

    xProgress              := 'ADVOB-10-1302';
Line: 864

      **  Update ECE_ADVO_HEADERS to archive the current Advice header.
      **
      */

      UPDATE ece_advo_headers
         SET edi_processed_flag = 'Y',
             edi_process_date   = SYSDATE
       WHERE advice_header_id   = l_header_tbl(n_advice_header_id_pos).value;
Line: 877

                      'ECE_NO_ROW_UPDATED',
                      'PROGRESS_LEVEL',
                      xProgress,
                      'INFO',
                      'EDI_PROCESSED_FLAG',
                      'TABLE_NAME',
                      'ECE_ADVO_HEADERS' );
Line: 914

      **  insert this record into the Header interface table.
      **
      */

      xProgress := 'ADVOB-10-1350';
Line: 920

        SELECT ece_advo_headers_interface_s.nextval
          INTO l_header_fkey
          FROM sys.dual;
Line: 937

      ece_Extract_Utils_PUB.insert_into_interface_tbl ( iRun_id,
                                                        cTransaction_Type,
                                                        cCommunication_Method,
                                                        cHeader_Interface,
                                                        l_header_tbl,
                                                        l_header_fkey );
Line: 958

      **  the SELECT clause of the Line level.
      **
      */

      xProgress := 'ADVOB-10-1380';
Line: 969

      **  Execute the Line level SELECT statement.
      **
      */

      xProgress := 'ADVOB-10-1390';
Line: 1022

        **  insert this record into the Line interface table.
        **
        */

        xProgress := 'ADVOB-10-1430';
Line: 1028

          SELECT ece_advo_details_interface_s.nextval
            INTO l_line_fkey
            FROM sys.dual;
Line: 1045

        ece_Extract_Utils_PUB.insert_into_interface_tbl ( iRun_id,
                                                          cTransaction_Type,
                                                          cCommunication_Method,
                                                          cLine_Interface,
                                                          l_line_tbl,
                                                          l_line_fkey );
Line: 1210

    cHeader_select           VARCHAR2(32000);
Line: 1211

    cLine_select             VARCHAR2(32000);
Line: 1219

    cHeader_delete1          VARCHAR2(32000);
Line: 1220

    cLine_delete1            VARCHAR2(32000);
Line: 1222

    cHeader_delete2          VARCHAR2(32000);
Line: 1223

    cLine_delete2            VARCHAR2(32000);
Line: 1261

    **  The 'select_clause' procedure will build the SELECT, FROM and WHERE
    **  clauses in preparation for the dynamic SQL call using the EDI data
    **  dictionary for the build.  Any necessary customizations to these
    **  clauses need to be made *after* the clause is built, but *before*
    **  the SQL call.
    **
    */


    xProgress := 'ADVOB-20-1020';
Line: 1271

    ece_flatfile_pvt.select_clause ( cTransaction_Type,
                                     cCommunication_Method,
                                     cHeader_Interface,
                                     cHeader_X_Interface,
                                     l_header_tbl,
                                     c_header_common_key_name,
                                     cHeader_select,
                                     cHeader_from,
                                     cHeader_where );
Line: 1283

    ece_flatfile_pvt.select_clause ( cTransaction_Type,
                                     cCommunication_Method,
                                     cLine_Interface,
                                     cLine_X_Interface,
                                     l_line_tbl,
                                     c_line_common_key_name,
                                     cLine_select,
                                     cLine_from,
                                     cLine_where );
Line: 1296

    **  customize the SELECT clauses to include the ROWID.  Records
    **  will be deleted from the interface tables using these ROWID
    **  values.
    **
    */

    xProgress     := 'ADVOB-20-1040';
Line: 1321

    cHeader_select := cHeader_select                              ||
                      ','                                         ||
                      cHeader_Interface                           ||
                      '.ROWID, '                                  ||
                      cHeader_X_Interface                         ||
                      '.ROWID';
Line: 1329

    cLine_select   := cLine_select                                ||
                      ','                                         ||
                      cLine_Interface                             ||
                      '.ROWID,'                                   ||
                      cLine_X_Interface                           ||
                      '.ROWID';
Line: 1338

    **  Build the complete SELECT and DELETE statements
    **  for each level.
    **
    */

    xProgress      := 'ADVOB-20-1080';
Line: 1344

    cHeader_select := cHeader_select                              ||
                      cHeader_from                                ||
                      cHeader_where                               ||
                      ' FOR UPDATE';
Line: 1348

    ec_debug.pl ( 3, 'cHeader_select: ',cHeader_select );
Line: 1351

    cLine_select   := cLine_select                                ||
                      cLine_from                                  ||
                      cLine_where                                 ||
                      ' FOR UPDATE';
Line: 1355

    ec_debug.pl ( 3, 'cLine_select: ',cLine_select );
Line: 1358

    cHeader_delete1 := 'DELETE FROM '                             ||
                       cHeader_Interface                          ||
                       ' WHERE ROWID = :col_rowid';
Line: 1361

    ec_debug.pl ( 3, 'cHeader_delete1: ',cHeader_delete1 );
Line: 1364

    cLine_delete1   := 'DELETE FROM '                             ||
                       cLine_Interface                            ||
                       ' WHERE ROWID = :col_rowid';
Line: 1367

    ec_debug.pl ( 3, 'cLine_delete1: ',cLine_delete1 );
Line: 1370

    cHeader_delete2 := 'DELETE FROM '                             ||
                       cHeader_X_Interface                        ||
                       ' WHERE ROWID = :col_rowid';
Line: 1373

    ec_debug.pl ( 3, 'cHeader_delete2: ',cHeader_delete2 );
Line: 1376

    cLine_delete2   := 'DELETE FROM '                             ||
                       cLine_X_Interface                          ||
                       ' WHERE ROWID = :col_rowid';
Line: 1379

    ec_debug.pl ( 3, 'cLine_delete2: ',cLine_delete2 );
Line: 1383

    **  Open a cursor for each SELECT and DELETE call.  This tells
    **  the database to reserve space for the data returned by the
    **  SELECT and DELETE statements.
    **
    */

    xProgress     := 'ADVOB-20-1140';
Line: 1409

    **  Parse each SELECT and DELETE statement so the database understands
    **  the command.
    **
    */

    xProgress := 'ADVOB-20-1200';
Line: 1417

                       cHeader_select,
                       dbms_sql.native );
Line: 1422

                                                   cHeader_select  );
Line: 1429

                       cLine_select,
                       dbms_sql.native );
Line: 1434

                                                   cLine_select );
Line: 1441

                       cHeader_delete1,
                       dbms_sql.native );
Line: 1446

                                                   cHeader_delete1  );
Line: 1453

                       cLine_delete1,
                       dbms_sql.native );
Line: 1458

                                                   cLine_delete1 );
Line: 1465

                       cHeader_delete2,
                       dbms_sql.native );
Line: 1470

                                                   cHeader_delete2 );
Line: 1477

                       cLine_delete2,
                       dbms_sql.native );
Line: 1482

                                                   cLine_delete2 );
Line: 1503

    **  SELECT statement so the database understands how to
    **  populate it.
    **
    */

    xProgress := 'ADVOB-20-1280';
Line: 1513

                               cHeader_select,
                               ece_flatfile_pvt.G_MaxColWidth );
Line: 1520

    **  DELETE statements.
    **
    */

    xProgress := 'ADVOB-20-1290';
Line: 1537

    **  SELECT statement so the database understands how to
    **  populate it.
    **
    */

    xProgress := 'ADVOB-20-1310';
Line: 1547

                               cLine_select,
                               ece_flatfile_pvt.G_MaxColWidth );
Line: 1554

    **  DELETE statements.
    **
    */

    xProgress := 'ADVOB-20-1320';
Line: 1608

    **  Execute the Header level SELECT statement.
    **
    */

    xProgress := 'ADVOB-20-1380';
Line: 1693

      **  SELECT clause.
      **
      */

      xProgress := 'ADVOB-20-1460';
Line: 1710

      **  Execute the Line level SELECT statement.
      **
      */

      xProgress := 'ADVOB-20-1470';
Line: 1792

        **  Bind the variables (ROWIDs) in the DELETE statements.
        **
        */

        xProgress := 'ADVOB-20-1540';
Line: 1808

        **  Delete the rows from the interface table.
        **
        */

        xProgress := 'ADVOB-20-1560';
Line: 1837

      **  Bind the variables (ROWIDs) in the DELETE statements.
      **
      */

      xProgress := 'ADVOB-20-1580';
Line: 1853

      **  Delete the rows from the interface table.
      **
      */

      xProgress := 'ADVOB-20-1600';