DBA Data[Home] [Help]

APPS.IGS_HE_UT_CALC_TYPE_PKG SQL Statements

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

Line: 17

    x_last_update_date                  IN     DATE,
    x_last_updated_by                   IN     NUMBER,
    x_last_update_login                 IN     NUMBER,
    x_report_all_hierarchy_flag         IN     VARCHAR2
  ) AS
  /*
  ||  Created By : [email protected]
  ||  Created On : 11-FEB-2003
  ||  Purpose : Initialises the Old and New references for the columns of the table.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */

    CURSOR cur_old_ref_values IS
      SELECT   *
      FROM     igs_he_ut_calc_type
      WHERE    rowid = x_rowid;
Line: 45

    IF ((cur_old_ref_values%NOTFOUND) AND (p_action NOT IN ('INSERT', 'VALIDATE_INSERT'))) THEN
      CLOSE cur_old_ref_values;
Line: 47

      fnd_message.set_name ('FND', 'FORM_RECORD_DELETED');
Line: 61

    IF (p_action = 'UPDATE') THEN
      new_references.creation_date                   := old_references.creation_date;
Line: 69

    new_references.last_update_date                  := x_last_update_date;
Line: 70

    new_references.last_updated_by                   := x_last_updated_by;
Line: 71

    new_references.last_update_login                 := x_last_update_login;
Line: 109

      SELECT   rowid
      FROM     igs_he_ut_calc_type
      WHERE    tariff_calc_type_cd = x_tariff_calc_type_cd
      AND  closed_ind  =  NVL(x_closed_ind,closed_ind)
      FOR UPDATE NOWAIT ;
Line: 147

      SELECT   rowid
      FROM     igs_he_ut_calc_type
      WHERE    external_calc_ind   = 'Y'
      AND      closed_ind          = 'N'
      AND      ((l_rowid IS NULL) OR (rowid <> l_rowid)) ;
Line: 203

    x_last_update_date                  IN     DATE,
    x_last_updated_by                   IN     NUMBER,
    x_last_update_login                 IN     NUMBER,
    x_report_all_hierarchy_flag         IN     VARCHAR2
  ) AS
  /*
  ||  Created By : [email protected]
  ||  Created On : 11-FEB-2003
  ||  Purpose : Initialises the columns, Checks Constraints, Calls the
  ||            Trigger Handlers for the table, before any DML operation.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */
  BEGIN

    set_column_values (
      p_action,
      x_rowid,
      x_tariff_calc_type_cd,
      x_tariff_calc_type_desc,
      x_external_calc_ind,
      x_closed_ind,
      x_creation_date,
      x_created_by,
      x_last_update_date,
      x_last_updated_by,
      x_last_update_login,
      x_report_all_hierarchy_flag
    );
Line: 235

    IF (p_action = 'INSERT') THEN
      -- Call all the procedures related to Before Insert.
      IF ( get_pk_for_validation(
             new_references.tariff_calc_type_cd,
             NULL
           )
         ) THEN
        fnd_message.set_name('IGS','IGS_HE_UT_CALC_TYPE_EXISTS');
Line: 248

    ELSIF (p_action = 'UPDATE') THEN
      -- Call all the procedures related to Before Update.
      check_uniqueness;
Line: 251

    ELSIF (p_action = 'DELETE') THEN
      -- Call all the procedures related to Before Delete.
      check_child_existance;
Line: 254

    ELSIF (p_action = 'VALIDATE_INSERT') THEN
      -- Call all the procedures related to Before Insert.
      IF ( get_pk_for_validation (
             new_references.tariff_calc_type_cd,
             NULL
           )
         ) THEN
        fnd_message.set_name('IGS','IGS_HE_UT_CALC_TYPE_EXISTS');
Line: 267

    ELSIF (p_action = 'VALIDATE_UPDATE') THEN
       check_uniqueness;
Line: 269

    ELSIF (p_action = 'VALIDATE_DELETE') THEN
       check_child_existance;
Line: 273

    IF (p_action IN ('VALIDATE_INSERT', 'VALIDATE_UPDATE', 'VALIDATE_DELETE') ) THEN
      l_rowid := NULL;
Line: 280

  PROCEDURE insert_row (
    x_rowid                             IN OUT NOCOPY VARCHAR2,
    x_tariff_calc_type_cd               IN     VARCHAR2,
    x_tariff_calc_type_desc             IN     VARCHAR2,
    x_external_calc_ind                 IN     VARCHAR2,
    x_closed_ind                        IN     VARCHAR2,
    x_report_all_hierarchy_flag         IN     VARCHAR2,
    x_mode                              IN     VARCHAR2
  ) AS
  /*
  ||  Created By : [email protected]
  ||  Created On : 11-FEB-2003
  ||  Purpose : Handles the INSERT DML logic for the table.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */

    x_last_update_date           DATE;
Line: 300

    x_last_updated_by            NUMBER;
Line: 301

    x_last_update_login          NUMBER;
Line: 305

    x_last_update_date := SYSDATE;
Line: 307

      x_last_updated_by := 1;
Line: 308

      x_last_update_login := 0;
Line: 310

      x_last_updated_by := fnd_global.user_id;
Line: 311

      IF (x_last_updated_by IS NULL) THEN
        x_last_updated_by := -1;
Line: 314

      x_last_update_login := fnd_global.login_id;
Line: 315

      IF (x_last_update_login IS NULL) THEN
        x_last_update_login := -1;
Line: 320

      fnd_message.set_token ('ROUTINE', 'IGS_HE_UT_CALC_TYPE_PKG.INSERT_ROW');
Line: 326

      p_action                            => 'INSERT',
      x_rowid                             => x_rowid,
      x_tariff_calc_type_cd               => x_tariff_calc_type_cd,
      x_tariff_calc_type_desc             => x_tariff_calc_type_desc,
      x_external_calc_ind                 => x_external_calc_ind,
      x_closed_ind                        => x_closed_ind,
      x_creation_date                     => x_last_update_date,
      x_created_by                        => x_last_updated_by,
      x_last_update_date                  => x_last_update_date,
      x_last_updated_by                   => x_last_updated_by,
      x_last_update_login                 => x_last_update_login,
      x_report_all_hierarchy_flag         => x_report_all_hierarchy_flag
    );
Line: 340

    INSERT INTO igs_he_ut_calc_type (
      tariff_calc_type_cd,
      tariff_calc_type_desc,
      external_calc_ind,
      closed_ind,
      creation_date,
      created_by,
      last_update_date,
      last_updated_by,
      last_update_login,
      report_all_hierarchy_flag
    ) VALUES (
      new_references.tariff_calc_type_cd,
      new_references.tariff_calc_type_desc,
      new_references.external_calc_ind,
      new_references.closed_ind,
      x_last_update_date,
      x_last_updated_by,
      x_last_update_date,
      x_last_updated_by,
      x_last_update_login,
      new_references.report_all_hierarchy_flag
    ) RETURNING ROWID INTO x_rowid;
Line: 366

  END insert_row;
Line: 387

      SELECT
        tariff_calc_type_desc,
        external_calc_ind,
        closed_ind,
        report_all_hierarchy_flag
      FROM  igs_he_ut_calc_type
      WHERE rowid = x_rowid
      FOR UPDATE NOWAIT;
Line: 403

      fnd_message.set_name('FND', 'FORM_RECORD_DELETED');
Line: 429

  PROCEDURE update_row (
    x_rowid                             IN     VARCHAR2,
    x_tariff_calc_type_cd               IN     VARCHAR2,
    x_tariff_calc_type_desc             IN     VARCHAR2,
    x_external_calc_ind                 IN     VARCHAR2,
    x_closed_ind                        IN     VARCHAR2,
    x_report_all_hierarchy_flag         IN     VARCHAR2,
    x_mode                              IN     VARCHAR2
  ) AS
  /*
  ||  Created By : [email protected]
  ||  Created On : 11-FEB-2003
  ||  Purpose : Handles the UPDATE DML logic for the table.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */
    x_last_update_date           DATE ;
Line: 448

    x_last_updated_by            NUMBER;
Line: 449

    x_last_update_login          NUMBER;
Line: 453

    x_last_update_date := SYSDATE;
Line: 455

      x_last_updated_by := 1;
Line: 456

      x_last_update_login := 0;
Line: 458

      x_last_updated_by := fnd_global.user_id;
Line: 459

      IF x_last_updated_by IS NULL THEN
        x_last_updated_by := -1;
Line: 462

      x_last_update_login := fnd_global.login_id;
Line: 463

      IF (x_last_update_login IS NULL) THEN
        x_last_update_login := -1;
Line: 468

      fnd_message.set_token ('ROUTINE', 'IGS_HE_UT_CALC_TYPE_PKG.UPDATE_ROW');
Line: 474

      p_action                            => 'UPDATE',
      x_rowid                             => x_rowid,
      x_tariff_calc_type_cd               => x_tariff_calc_type_cd,
      x_tariff_calc_type_desc             => x_tariff_calc_type_desc,
      x_external_calc_ind                 => x_external_calc_ind,
      x_closed_ind                        => x_closed_ind,
      x_creation_date                     => x_last_update_date,
      x_created_by                        => x_last_updated_by,
      x_last_update_date                  => x_last_update_date,
      x_last_updated_by                   => x_last_updated_by,
      x_last_update_login                 => x_last_update_login,
      x_report_all_hierarchy_flag         => x_report_all_hierarchy_flag
    );
Line: 488

    UPDATE igs_he_ut_calc_type
      SET
        tariff_calc_type_desc             = new_references.tariff_calc_type_desc,
        external_calc_ind                 = new_references.external_calc_ind,
        closed_ind                        = new_references.closed_ind,
        last_update_date                  = x_last_update_date,
        last_updated_by                   = x_last_updated_by,
        last_update_login                 = x_last_update_login,
        report_all_hierarchy_flag         = new_references.report_all_hierarchy_flag
      WHERE rowid = x_rowid;
Line: 505

  END update_row;
Line: 520

  ||  Purpose : Adds a row if there is no existing row, otherwise updates existing row in the table.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */
    CURSOR c1 IS
      SELECT   rowid
      FROM     igs_he_ut_calc_type
      WHERE    tariff_calc_type_cd               = x_tariff_calc_type_cd;
Line: 538

      insert_row (
        x_rowid,
        x_tariff_calc_type_cd,
        x_tariff_calc_type_desc,
        x_external_calc_ind,
        x_closed_ind,
        x_report_all_hierarchy_flag,
        x_mode
      );
Line: 551

    update_row (
      x_rowid,
      x_tariff_calc_type_cd,
      x_tariff_calc_type_desc,
      x_external_calc_ind,
      x_closed_ind,
      x_report_all_hierarchy_flag,
      x_mode
    );
Line: 564

  PROCEDURE delete_row (
    x_rowid IN VARCHAR2
  ) AS
  /*
  ||  Created By : [email protected]
  ||  Created On : 11-FEB-2003
  ||  Purpose : Handles the DELETE DML logic for the table.
  ||  Known limitations, enhancements or remarks :
  ||  Change History :
  ||  Who             When            What
  ||  (reverse chronological order - newest change first)
  */
  BEGIN

    before_dml (
      p_action => 'DELETE',
      x_rowid => x_rowid
    );
Line: 583

    DELETE FROM igs_he_ut_calc_type
    WHERE rowid = x_rowid;
Line: 592

  END delete_row;