DBA Data[Home] [Help]

APPS.OZF_TP_ACCRUAL_PVT SQL Statements

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

Line: 52

SELECT 1
FROM ozf_offers
WHERE qp_list_header_id = p_list_header_id;
Line: 57

SELECT 1
FROM ozf_resale_adjustments
WHERE resale_line_id = p_line_id
AND list_header_id = p_list_header_id
AND list_line_id = p_list_line_id;
Line: 130

SELECT status_code
,      org_id
from ozf_resale_batches
WHERE resale_batch_id = p_resale_batch_id;
Line: 175

         INSERT INTO ozf_resale_logs_all(
            resale_log_id,
            resale_id,
            resale_id_type,
            error_code,
            error_message,
            column_name,
            column_value,
            org_id
         ) SELECT
               ozf_resale_logs_all_s.nextval,
               p_resale_batch_id,
               'BATCH',
               'OZF_BATCH_STATUS_WNG',
               FND_MESSAGE.get_string('OZF','OZF_BATCH_STATUS_WNG'),
               'STATUS_CODE',
               l_status_code,
               l_org_id
           FROM dual
           WHERE NOT EXISTS (
               SELECT 1
               FROM ozf_resale_logs a
               WHERE a.resale_id = p_resale_batch_id
               AND   a.resale_id_type = 'BATCH'
               AND   a.error_code = 'OZF_BATCH_STATUS_WNG'
           );
Line: 308

         INSERT INTO ozf_resale_logs_all(
            resale_log_id,
            resale_id,
            resale_id_type,
            error_code,
            error_message,
            column_name,
            column_value,
            org_id
         ) SELECT
               ozf_resale_logs_all_s.nextval,
               resale_line_int_id,
               'IFACE',
               'OZF_RESALE_SELL_PRICE_NULL',
               FND_MESSAGE.get_string('OZF','OZF_RESALE_SELL_PRICE_NULL'),
               'SELLING_PRICE',
               NULL,
               org_id
           FROM ozf_resale_lines_int_all b
           WHERE b.status_code = 'OPEN'
           AND b.direct_customer_flag = 'T'
           AND b.selling_price IS NULL
           AND b.resale_batch_id = p_resale_batch_id
           AND NOT EXISTS(
               SELECT 1
               FROM ozf_resale_logs_all a
               WHERE a.resale_id = b.resale_line_int_id
               AND a.resale_id_type = 'IFACE'
               AND a.error_code ='OZF_RESALE_SELL_PRICE_NULL'
           );
Line: 345

         UPDATE ozf_resale_lines_int_all
         SET status_code = 'DISPUTED',
             dispute_code = 'OZF_RESALE_SELL_PRICE_NULL'
         WHERE status_code = 'OPEN'
         AND direct_customer_flag = 'T'
         AND selling_price IS NULL
         AND resale_batch_id = p_resale_batch_id;
Line: 360

        INSERT INTO ozf_resale_logs_all(
           resale_log_id,
           resale_id,
           resale_id_type,
           error_code,
           error_message,
           column_name,
           column_value,
           org_id
       ) SELECT
            ozf_resale_logs_all_s.nextval,
            b.resale_line_id,
            'LINE',
            'OZF_RESALE_SELL_PRICE_NULL',
            FND_MESSAGE.get_string('OZF','OZF_RESALE_SELL_PRICE_NULL'),
            'SELLING_PRICE',
            NULL,
            b.org_id
         FROM ozf_resale_lines_all b
            , ozf_resale_batch_line_maps_all c
         WHERE b.direct_customer_flag = 'T'
         AND b.selling_price IS NULL
         AND b.resale_line_id = c.resale_line_id
         AND c.resale_batch_id = p_resale_batch_id
         AND NOT EXISTS(SELECT 1
            FROM ozf_resale_logs_all a
            WHERE a.resale_id = b.resale_line_id
            AND a.resale_id_type = 'LINE'
            AND a.error_code ='OZF_RESALE_SELL_PRICE_NULL'
         );
Line: 482

   SELECT *
   FROM qp_ldets_v
   WHERE line_index = p_index
   ORDER BY pricing_group_sequence;
Line: 518

SELECT a.orig_system_agreement_uom,
       a.orig_system_agreement_name,
       a.orig_system_agreement_type,
       a.orig_system_agreement_status,
       a.orig_system_agreement_curr,
       a.orig_system_agreement_price,
       a.orig_system_agreement_quantity,
       a.agreement_id, a.agreement_type,
       a.agreement_name, a.agreement_price,
       a.agreement_uom_code,
       a.corrected_agreement_id,
       a.corrected_agreement_name,
       a.credit_code,
       a.credit_advice_date
FROM ozf_resale_adjustments a, ozf_resale_batches b
WHERE a.resale_line_id = p_line_id
AND a.resale_batch_id = p_batch_id
AND a.line_agreement_flag = 'T'
AND a.resale_batch_id = b.resale_batch_id
AND b.batch_type = OZF_RESALE_COMMON_PVT.G_CHARGEBACK
AND rownum = 1;
Line: 547

   SELECT party_id
   FROM hz_cust_accounts
   WHERE cust_account_id = p_cust_account_id;
Line: 552

   SELECT party_site_id
   FROM hz_cust_acct_sites
   WHERE cust_acct_site_id = p_account_site_id;
Line: 560

SELECT offer_type
FROM   ozf_offers
WHERE  qp_list_header_id = p_qp_list_header_id;
Line: 589

      OZF_RESALE_COMMON_PVT.Insert_resale_line(
         p_api_version       => 1
        ,p_init_msg_list     => FND_API.G_FALSE
        ,p_commit            => FND_API.G_FALSE
        ,p_validation_level  => FND_API.G_VALID_LEVEL_FULL
        ,p_line_int_rec      => p_resale_line_int_rec
        ,p_header_id         => p_header_id
        ,x_line_id           => l_line_id
        ,x_return_status     => l_return_status
        ,x_msg_data          => l_msg_data
        ,x_msg_count         => l_msg_count
      );
Line: 606

      OZF_RESALE_COMMON_PVT.Insert_Resale_Line_Mapping(
          p_api_version            => 1
         ,p_init_msg_list          => FND_API.G_FALSE
         ,p_commit                 => FND_API.G_FALSE
         ,p_validation_level       => FND_API.G_VALID_LEVEL_FULL
         ,p_resale_batch_id        => p_resale_batch_id
         ,p_line_id                => l_line_id
         ,x_return_status          => l_return_status
         ,x_msg_data               => l_msg_data
         ,x_msg_count              => l_msg_count
      );
Line: 646

         OZF_SALES_TRANSACTIONS_PVT.update_inventory_tmp (
            p_api_version      => 1.0
           ,p_init_msg_list    => FND_API.G_FALSE
           ,p_validation_level => FND_API.G_VALID_LEVEL_FULL
           ,p_sales_transaction_id => l_sales_transaction_id
           ,x_return_status    => l_return_status
           ,x_msg_data         => l_msg_data
           ,x_msg_count        => l_msg_count
         );
Line: 673

      l_ldets_tbl.DELETE;
Line: 804

                        OZF_VOLUME_CALCULATION_PUB.Update_Tracking_Line(
                           p_init_msg_list     => FND_API.g_false
                          ,p_api_version       => 1.0
                          ,p_commit            => FND_API.g_false
                          ,x_return_status     => l_return_status
                          ,x_msg_count         => l_msg_count
                          ,x_msg_data          => l_msg_data
                          ,p_list_header_id    => l_ldets_tbl(k).list_header_id
                          ,p_interface_line_id => p_resale_line_int_rec.resale_line_int_id
                          ,p_resale_line_id    => l_line_id
                        );
Line: 1250

   SELECT order_number
        , bill_to_cust_account_id
        , date_ordered
   FROM ozf_resale_lines_int_all
   WHERE resale_line_int_id = p_id;
Line: 1257

   SELECT resale_header_id
   FROM ozf_resale_lines
   WHERE resale_line_id = p_id;
Line: 1269

  SELECT *
  FROM ozf_resale_lines
  WHERE resale_line_id = p_id;
Line: 1280

   SELECT exchange_rate_type
   FROM   ozf_sys_parameters;
Line: 1291

   SELECT gs.currency_code
   FROM   gl_sets_of_books gs,
          ozf_sys_parameters osp
   WHERE  gs.set_of_books_id = osp.set_of_books_id
   AND    osp.org_id = MO_GLOBAL.GET_CURRENT_ORG_ID(); -- BUG 5058027
Line: 1305

   SELECT 1
   FROM ozf_resale_lines_int_all
   WHERE resale_batch_id = p_id
   AND order_number = p_order_number
   AND bill_to_cust_account_id = p_cust_id
   AND date_ordered = p_date
   AND status_code = 'DUPLICATED';
Line: 1323

   SELECT a.resale_header_id
   FROM ozf_resale_headers_all a
      , ozf_resale_lines_int_all b
      , ozf_resale_lines_all c
   WHERE b.resale_batch_id = p_id
   AND b.order_number = p_order_number
   AND b.bill_to_cust_account_id = p_cust_id
   AND b.date_ordered = p_date
   AND b.status_code = 'DUPLICATED'
   AND b.duplicated_line_id = c.resale_line_id
   AND c.resale_header_id = a.resale_header_id;
Line: 1339

   SELECT partner_cust_account_id,
          partner_party_id,
          report_start_date,
          report_end_date,
          last_updated_by
   FROM ozf_resale_batches_all
   WHERE resale_batch_id = p_id;
Line: 1351

l_last_updated_by            NUMBER(15);
Line: 1373

                             l_last_updated_by;
Line: 1401

                        p_line_tbl(i).pricing_status_code <> QP_PREQ_PUB.G_STATUS_UPDATED;
Line: 1411

               UPDATE ozf_resale_lines_int_all
               SET status_code = 'DISPUTED'
               WHERE status_code = 'OPEN'
               AND order_NUMBER = l_order_number
               AND bill_to_cust_account_id = l_cust_account_id
               AND date_ordered = l_date_ordered
               AND resale_batch_id = p_resale_batch_id;
Line: 1445

               OZF_RESALE_LOGS_PKG.Insert_Row(
                    px_resale_log_id           => l_log_id,
                    p_resale_id                => p_line_tbl(i).chargeback_int_id,
                    p_resale_id_type           => l_id_type,
                    p_error_code               => p_line_tbl(i).pricing_status_code,
                    p_error_message            => p_line_tbl(i).pricing_status_text,                    p_column_name              => NULL,
                    p_column_value             => NULL,
                    --px_org_id                  => OZF_RESALE_COMMON_PVT.g_org_id
                    px_org_id                  => l_org_id
               );
Line: 1574

                        OZF_RESALE_COMMON_PVT.Insert_Resale_Log (
                           p_id_value      => l_resale_int_rec.resale_line_int_id,
                           p_id_type       => 'IFACE',
                           p_error_code    => 'OZF_RESALE_INV_LEVEL_ERROR',
                           p_column_name   => NULL,
                           p_column_value  => NULL,
                           x_return_status => l_return_status
                        );
Line: 1589

                        UPDATE ozf_resale_lines_int_all
                        SET resale_batch_id = null,
                            request_id = null,
                            status_code = 'DISPUTED',
                            dispute_code = 'OZF_LT_INVT'
                        WHERE resale_line_int_id = l_resale_int_rec.resale_line_int_id;
Line: 1612

                        OZF_RESALE_COMMON_PVT.Insert_Resale_Header(
                              p_api_version       => 1
                             ,p_init_msg_list     => FND_API.G_FALSE
                             ,p_commit            => FND_API.G_FALSE
                             ,p_validation_level  => FND_API.G_VALID_LEVEL_FULL
                             ,p_line_int_rec      => l_resale_int_rec
                             ,x_header_id         => l_header_id
                             ,x_return_status     => l_return_status
                             ,x_msg_data          => l_msg_data
                             ,x_msg_count         => l_msg_count
                        );
Line: 1727

                  p_approver_id          => l_last_updated_by,
                  x_return_status        => l_return_status
               );
Line: 1734

                        UPDATE ozf_resale_lines_int_all
                        SET resale_batch_id = NULL,
                            request_id = NULL,
                            status_code = 'DISPUTED',
                            dispute_code = 'OZF_PRIC_RESULT_ERR'
                        WHERE resale_line_int_id = p_line_tbl(i).chargeback_int_id;
Line: 1750

                        UPDATE ozf_resale_lines_int_all
                        SET status_code= 'CLOSED'
                        WHERE resale_line_int_id = p_line_tbl(i).chargeback_int_id;
Line: 1815

   SELECT a.resale_header_id
   ,      a.header_attribute_category
   ,      a.header_attribute1
   ,      a.header_attribute2
   ,      a.header_attribute3
   ,      a.header_attribute4
   ,      a.header_attribute5
   ,      a.header_attribute6
   ,      a.header_attribute7
   ,      a.header_attribute8
   ,      a.header_attribute9
   ,      a.header_attribute10
   ,      a.header_attribute11
   ,      a.header_attribute12
   ,      a.header_attribute13
   ,      a.header_attribute14
   ,      a.header_attribute15
   FROM ozf_resale_headers_all a
      , ozf_resale_lines_all b
      , ozf_resale_batch_line_maps_all c
   WHERE a.resale_header_id = b.resale_header_id
   AND b.resale_line_id = c.resale_line_id
   AND c.resale_batch_id = p_resale_batch_id;
Line: 1843

SELECT *
FROM ozf_resale_headers
WHERE resale_header_id = p_header_id;
Line: 1850

SELECT *
FROM ozf_resale_lines
WHERE resale_header_id = p_header_id;
Line: 1941

   l_control_rec.TEMP_TABLE_INSERT_FLAG := 'N';
Line: 1944

      l_header_id_tbl.DELETE;
Line: 1993

            IF l_order_set_tbl.EXISTS(1) THEN l_order_set_tbl.DELETE; END IF;
Line: 1994

            IF l_line_tbl.EXISTS(1)      THEN l_line_tbl.DELETE; END IF;
Line: 1995

            IF l_ldets_tbl.EXISTS(1)      THEN l_ldets_tbl.DELETE; END IF;
Line: 1996

            IF l_related_lines_tbl.EXISTS(1) THEN l_related_lines_tbl.DELETE; END IF;
Line: 1997

            IF OZF_ORDER_PRICE_PVT.G_LINE_REC_TBL.EXISTS(1) THEN OZF_ORDER_PRICE_PVT.G_LINE_REC_TBL.DELETE; END IF;
Line: 1998

            IF OZF_ORDER_PRICE_PVT.G_RESALE_LINE_TBL.EXISTS(1) THEN OZF_ORDER_PRICE_PVT.G_RESALE_LINE_TBL.DELETE; END IF;
Line: 2025

                     DELETE FROM ozf_resale_logs
                     WHERE resale_id = l_order_set_tbl(J).resale_line_id
                     AND   resale_id_type = OZF_RESALE_COMMON_PVT.G_ID_TYPE_LINE;
Line: 2259

                        OZF_RESALE_LOGS_PKG.Insert_Row(
                           px_resale_log_id           => l_log_id,
                           p_resale_id                => l_order_set_tbl(p).resale_line_id,
                           p_resale_id_type           => OZF_RESALE_COMMON_PVT.G_ID_TYPE_LINE,
                           p_error_code               => 'OZF_GET_ORDER_PRIC_ERR',
                           p_error_message            => fnd_message.get_string('OZF','OZF_GET_ORDER_PRIC_ERR'),
                           p_column_name              => NULL,
                           p_column_value             => NULL,
                           --px_org_id                  => OZF_RESALE_COMMON_PVT.g_org_id
                           px_org_id                  => l_org_id
                        );
Line: 2323

                        OZF_RESALE_LOGS_PKG.Insert_Row(
                           px_resale_log_id           => l_log_id,
                           p_resale_id                => l_order_set_tbl(i).resale_line_id,
                           p_resale_id_type           => OZF_RESALE_COMMON_PVT.G_ID_TYPE_LINE,
                           p_error_code               => 'OZF_PROC_PRIC_RESLT_ERR',
                           p_error_message            => fnd_message.get_string('OZF','OZF_PROC_PRIC_RESLT_ERR'),
                           p_column_name              => NULL,
                           p_column_value             => NULL,
                           --px_org_id                  => OZF_RESALE_COMMON_PVT.g_org_id
                           px_org_id                  => l_org_id
                        );
Line: 2594

SELECT (TO_NUMBER(SUBSTRB(USERENV('CLIENT_INFO'), 1, 10)))
FROM   dual; */
Line: 2598

  SELECT org_id
  FROM ozf_resale_batches_all
  WHERE resale_batch_id = cv_resale_batch_id;
Line: 2604

SELECT distinct order_NUMBER,
                bill_to_cust_account_id,
                date_ordered
FROM ozf_resale_lines_int
WHERE status_code=OZF_RESALE_COMMON_PVT.G_BATCH_ADJ_OPEN
AND direct_customer_flag = 'F'
AND resale_batch_id = p_resale_batch_id
ORDER BY date_ordered;
Line: 2620

SELECT *
FROM ozf_resale_lines_int
WHERE order_NUMBER = p_num
AND bill_to_cust_account_id = p_name
AND date_ordered = p_date
AND direct_customer_flag ='F'
AND status_code = OZF_RESALE_COMMON_PVT.G_BATCH_ADJ_OPEN
AND resale_batch_id = p_resale_batch_id;
Line: 2683

      l_order_num_tbl.DELETE;
Line: 2714

         DELETE FROM ozf_resale_logs_all a
         WHERE a.resale_id_type = 'IFACE'
         AND a.resale_id IN (
            SELECT resale_line_int_id
            FROM ozf_resale_lines_int_all b
            WHERE b.direct_customer_flag = 'F'
            AND b.status_code = 'OPEN'
            AND b.order_number = l_order_num_tbl(i).order_number
            AND b.bill_to_cust_account_id = l_order_num_tbl(i).bill_to_cust_account_id
            AND b.date_ordered = l_order_num_tbl(i).date_ordered
            AND b.resale_batch_id = p_resale_batch_id
         );
Line: 2735

                  OZF_RESALE_COMMON_PVT.Insert_resale_header(
                     p_api_version       => 1
                     ,p_init_msg_list     => FND_API.G_FALSE
                     ,p_commit            => FND_API.G_FALSE
                     ,p_validation_level  => FND_API.G_VALID_LEVEL_FULL
                     ,p_line_int_rec      => l_resale_int_tbl(k)
                     ,x_header_id         => l_header_id
                     ,x_return_status     => l_return_status
                     ,x_msg_data          => l_msg_data
                     ,x_msg_count         => l_msg_count
                  );
Line: 2751

               OZF_RESALE_COMMON_PVT.Insert_resale_line(
                  p_api_version       => 1
                 ,p_init_msg_list     => FND_API.G_FALSE
                 ,p_commit            => FND_API.G_FALSE
                 ,p_validation_level  => FND_API.G_VALID_LEVEL_FULL
                 ,p_line_int_rec      => l_resale_int_tbl(k)
                 ,p_header_id         => l_header_id
                 ,x_line_id           => l_line_id
                 ,x_return_status     => l_return_status
                 ,x_msg_data          => l_msg_data
                 ,x_msg_count         => l_msg_count
               );
Line: 2771

         UPDATE ozf_resale_lines_int
         SET status_code= OZF_RESALE_COMMON_PVT.G_BATCH_ADJ_CLOSED
         WHERE direct_customer_flag ='F'
         AND status_code = OZF_RESALE_COMMON_PVT.G_BATCH_ADJ_OPEN
         AND resale_batch_id = p_resale_batch_id;
Line: 2855

   SELECT DISTINCT order_NUMBER,
                   bill_to_cust_account_id,
                   date_ordered
   FROM ozf_resale_lines_int_all
   WHERE status_code IN ('OPEN', 'DUPLICATED')
   AND duplicated_adjustment_id IS NULL
   AND resale_batch_id = p_resale_batch_id
   ORDER BY date_ordered;
Line: 2873

SELECT *
FROM ozf_resale_lines_int_all
WHERE order_number = p_order_number
AND bill_to_cust_account_id= p_id
AND date_ordered = p_date
AND status_code IN ('OPEN', 'DUPLICATED')
AND duplicated_adjustment_id is NULL
AND resale_batch_id = p_resale_batch_id
AND tracing_flag = 'F';
Line: 2910

SELECT *
FROM ozf_resale_lines_int_all
WHERE order_number = p_order_number
AND bill_to_cust_account_id = p_id
AND date_ordered = p_date
AND status_code = 'DUPLICATED'
AND duplicated_adjustment_id IS NOT NULL
AND resale_batch_id = p_resale_batch_id
AND tracing_flag = 'F';
Line: 2924

SELECT *
FROM ozf_resale_lines_int_all
WHERE order_number = p_order_number -- ?? need this
AND bill_to_cust_account_id = p_id -- ?? need this
AND date_ordered = p_date
AND status_code IN ('OPEN', 'DUPLICATED')
AND resale_batch_id = p_resale_batch_id
AND tracing_flag = 'T';
Line: 2935

  SELECT COUNT(1)
  FROM ozf_resale_lines_int_all
  WHERE status_code IN ('PROCESSED', 'CLOSED', 'DUPLICATED')
  AND resale_batch_id = cv_batch_id;
Line: 2941

  SELECT batch_number
  FROM ozf_resale_batches_all
  WHERE resale_batch_id = cv_batch_id;
Line: 2949

   SELECT i.resale_line_int_id id
   ,      lk.meaning dispute_code
   ,      lg.error_message
   ,      lg.column_name
   ,      lg.column_value
   FROM ozf_resale_lines_int_all i
   , ozf_resale_logs_all lg
   , ozf_lookups lk
   WHERE i.dispute_code = lk.lookup_code(+)
   AND lk.lookup_type(+) = 'OZF_RESALE_DISPUTE_CODE'
   AND i.status_code = 'DISPUTED'
   AND i.resale_batch_id = cv_batch_id
   AND i.resale_line_int_id = lg.resale_id (+)
   ORDER BY i.resale_line_int_id;
Line: 3070

      l_output_dispute_line_tbl.DELETE;
Line: 3101

   UPDATE ozf_resale_lines_int
   SET resale_batch_id = null
   ,   request_id = null -- [BUG 4233341 FIXING]
   Where resale_batch_id = p_resale_batch_id
   and status_code = 'DISPUTED';
Line: 3154

   l_control_rec.temp_table_insert_flag   := 'N';
Line: 3158

      l_order_num_tbl.DELETE;
Line: 3202

            UPDATE ozf_resale_lines_int_all
            SET status_code= 'PROCESSED'
            WHERE status_code = 'OPEN'
            AND order_number = l_order_num_tbl(i).order_number
            AND bill_to_cust_account_id = l_order_num_tbl(i).bill_to_cust_account_id
            AND date_ordered = l_order_num_tbl(i).date_ordered
            AND tracing_flag = 'T'
            AND resale_batch_id = p_resale_batch_id; -- bug 5222273
Line: 3227

              IF l_order_set_tbl.EXISTS(1)     THEN l_order_set_tbl.DELETE; END IF;
Line: 3228

              IF l_line_tbl.EXISTS(1)          THEN l_line_tbl.DELETE; END IF;
Line: 3229

              IF l_ldets_tbl.EXISTS(1)         THEN l_ldets_tbl.DELETE; END IF;
Line: 3230

              IF l_related_lines_tbl.EXISTS(1) THEN l_related_lines_tbl.DELETE; END IF;
Line: 3231

              IF OZF_ORDER_PRICE_PVT.G_LINE_REC_TBL.EXISTS(1) THEN OZF_ORDER_PRICE_PVT.G_LINE_REC_TBL.DELETE; END IF;
Line: 3232

              IF OZF_ORDER_PRICE_PVT.G_RESALE_LINE_TBL.EXISTS(1) THEN OZF_ORDER_PRICE_PVT.G_RESALE_LINE_TBL.DELETE; END IF;
Line: 3257

                    DELETE FROM ozf_resale_logs
                    WHERE resale_id = l_order_set_tbl(j).resale_line_int_id
                    AND   resale_id_type = 'IFACE';
Line: 3495

                    UPDATE ozf_resale_lines_int
                    SET status_code = 'DISPUTED'
                    WHERE status_code = 'OPEN'
                    AND order_number = l_order_num_tbl(i).order_number
                    AND bill_to_cust_account_id = l_order_num_tbl(i).bill_to_cust_account_id
                    AND date_ordered = l_order_num_tbl(i).date_ordered
                    AND resale_batch_id = p_resale_batch_id;
Line: 3520

                       OZF_RESALE_LOGS_PKG.Insert_Row(
                            px_resale_log_id       => l_log_id,
                            p_resale_id            => l_order_set_tbl(p).resale_line_int_id,
                            p_resale_id_type       => 'IFACE',
                            p_error_code           => 'OZF_GET_ORDER_PRIC_ERR',
                            p_error_message        => FND_MESSAGE.get_string('OZF','OZF_GET_ORDER_PRIC_ERR'),
                            p_column_name          => NULL,
                            p_column_value         => NULL,
                            --px_org_id              => OZF_RESALE_COMMON_PVT.g_org_id
                            px_org_id              => l_org_id
                       );
Line: 3576

                       OZF_RESALE_LOGS_PKG.Insert_Row(
                         px_resale_log_id           => l_log_id,
                         p_resale_id                => l_order_set_tbl(p).resale_line_int_id,
                         p_resale_id_type           => 'IFACE',
                         p_error_code               => 'OZF_PRIC_RESULT_ERR',
                         p_error_message            => FND_MESSAGE.get_string('OZF','OZF_PRIC_RESULT_ERR'),
                         p_column_name              => NULL,
                         p_column_value             => NULL,
                         --px_org_id                  => OZF_RESALE_COMMON_PVT.g_org_id
                         px_org_id                  => l_org_id
                       );
Line: 3594

                    UPDATE ozf_resale_lines_int_all
                    SET status_code = 'DISPUTED'
                    WHERE status_code = 'OPEN'
                    AND order_number = l_order_num_tbl(i).order_number
                    AND bill_to_cust_account_id = l_order_num_tbl(i).bill_to_cust_account_id
                    AND date_ordered = l_order_num_tbl(i).date_ordered
                    AND resale_batch_id = p_resale_batch_id;
Line: 3667

      l_output_dispute_line_tbl.DELETE;
Line: 3699

   UPDATE ozf_resale_lines_int_all
   SET resale_batch_id = null
   ,   request_id = null
   WHERE resale_batch_id = p_resale_batch_id
   AND status_code IN ('NEW', 'OPEN', 'DISPUTED'); -- 'PROCESSED'
Line: 3711

      UPDATE ozf_resale_batches_all
      SET status_code = OZF_RESALE_COMMON_PVT.G_BATCH_CLOSED
      ,   batch_count = l_valid_line_count
      WHERE resale_batch_id = p_resale_batch_id;
Line: 3727

      DELETE FROM ozf_resale_batches_all
      WHERE resale_batch_id = p_resale_batch_id;
Line: 3816

SELECT resale_batch_id
FROM ozf_resale_batches
WHERE data_source_code = p_data_source_code;
Line: 3827

SELECT distinct sold_from_cust_account_id, org_id, currency_code
FROM ozf_resale_lines_int
WHERE resale_batch_id IS NULL
AND request_id = p_id;
Line: 3844

SELECT hca.party_id
-- bug # 7375849 fixed by ateotia (+)
--, substr(hp.party_name, 1,30)
, hp.party_name
-- bug # 7375849 fixed by ateotia (-)
FROM hz_cust_accounts hca
, hz_parties hp
WHERE hca.cust_account_id = p_id
AND hca.party_id = hp.party_id;
Line: 3860

SELECT ozf_resale_batches_all_s.nextval
  FROM dual;
Line: 3865

SELECT to_char(ozf_resale_batch_number_s.nextval)
  FROM dual;
Line: 3872

SELECT orli.created_from
     , orli.data_source_code
     , orli.sold_from_cust_account_id
     , orli.sold_from_site_id
     , orli.sold_from_contact_party_id
     , orli.sold_from_contact_name
     , orli.sold_from_email
     , orli.sold_from_phone
     , orli.sold_from_fax
     ,orli.currency_code
FROM  ozf_resale_lines_int orli
WHERE orli.resale_batch_id IS NULL
AND orli.sold_from_cust_account_id = p_id
AND orli.request_id = G_CONC_REQUEST_ID
AND orli.org_id = p_org_id
AND orli.currency_code = p_currency_code
AND rownum = 1;
Line: 3904

SELECT MIN(date_ordered), MAX(date_ordered)
FROM ozf_resale_lines_int_all
WHERE sold_from_cust_account_id = p_account_id
AND   request_id = FND_GLOBAL.CONC_REQUEST_ID
AND   org_id = p_org_id
AND   currency_code = p_currency_code;
Line: 3960

      UPDATE ozf_resale_lines_int_all
      SET   request_id = G_CONC_REQUEST_ID
      ,     dispute_code = null
      ,     program_application_id = FND_GLOBAL.PROG_APPL_ID
      ,     program_update_date = SYSDATE
      ,     program_id = FND_GLOBAL.CONC_PROGRAM_ID
      WHERE resale_batch_id IS NULL
      AND request_id IS NULL
      AND org_id = MO_GLOBAL.get_current_org_id();
Line: 3974

      UPDATE ozf_resale_lines_int_all
      SET   request_id = G_CONC_REQUEST_ID
      ,     dispute_code = null
      ,     program_application_id = FND_GLOBAL.PROG_APPL_ID
      ,     program_update_date = SYSDATE
      ,     program_id = FND_GLOBAL.CONC_PROGRAM_ID
      WHERE resale_batch_id IS NULL
      AND data_source_code = p_data_source_code
      AND request_id IS NULL
      AND org_id = MO_GLOBAL.get_current_org_id();
Line: 3986

   DELETE FROM ozf_resale_logs_all
   WHERE resale_id IN (SELECT resale_line_int_id
                       FROM ozf_resale_lines_int
                       WHERE request_id = G_CONC_REQUEST_ID)
   AND resale_id_type = 'IFACE';
Line: 4044

         OZF_RESALE_BATCHES_PKG.Insert_Row(
            px_resale_batch_id         => l_resale_batch_id,
            px_object_version_number   => l_obj_number,
            p_last_update_date         => SYSdate,
            p_last_updated_by          => NVL(FND_GLOBAL.user_id,-1),
            p_creation_date            => SYSdate,
            p_request_id               => G_CONC_REQUEST_ID,
            p_created_by               => NVL(FND_GLOBAL.user_id,-1),
            p_last_update_login        => NVL(FND_GLOBAL.conc_login_id,-1),
            p_program_application_id   => FND_GLOBAL.PROG_APPL_ID,
            p_program_update_date      => SYSdate,
            p_program_id               => FND_GLOBAL.CONC_PROGRAM_ID,
            p_created_from             => l_created_from,
            p_batch_number             => l_resale_batch_number,
            p_batch_type               => OZF_RESALE_COMMON_PVT.G_TP_ACCRUAL,
            p_batch_count              => NULL,
            p_year                     => NULL,
            p_month                    => NULL,
            p_report_date              => trunc(sysdate),
            p_report_start_date        => trunc(l_start_date),
            p_report_end_date          => trunc(l_end_date),
            p_status_code              => OZF_RESALE_COMMON_PVT.G_BATCH_NEW,
            p_data_source_code         => l_data_source_code,
            p_reference_type           => NULL,
            p_reference_number         => NULL,
            p_comments                 => NULL,
            p_partner_claim_number     => NULL,
            p_transaction_purpose_code => NULL,
            p_transaction_type_code    => NULL,
            p_partner_type             => NULL,
            p_partner_id               => NULL,
            p_partner_party_id         => l_party_id,
            p_partner_cust_account_id  => l_sold_from_cust_id_tbl(j) ,
            p_partner_site_id          => l_sold_from_site_id,
            p_partner_contact_party_id => l_sold_from_contact_party_id ,
            p_partner_contact_name     => l_sold_from_contact_name,
            p_partner_email            => l_sold_from_email,
            p_partner_phone            => l_sold_from_phone,
            p_partner_fax              => l_sold_from_fax,
            p_header_tolerance_operand    => NULL,
            p_header_tolerance_calc_code  => NULL,
            p_line_tolerance_operand      => NULL,
            p_line_tolerance_calc_code    => NULL,
            p_currency_code               => l_currency_code_tbl(j),
            p_claimed_amount      => NULL,
            p_allowed_amount      => NULL,
            p_paid_amount         => NULL,
            p_disputed_amount     => NULL,
            p_accepted_amount     => NULL,
            p_lines_invalid       => NULL,
            p_lines_w_tolerance   => NULL,
            p_lines_disputed      => NULL,
            p_batch_set_id_code   => NULL,
            p_credit_code         => NULL,
            p_credit_advice_date  => NULL,
            p_purge_flag          => NULL,
            p_attribute_category  => NULL,
            p_attribute1     => NULL,
            p_attribute2     => NULL,
            p_attribute3     => NULL,
            p_attribute4     => NULL,
            p_attribute5     => NULL,
            p_attribute6     => NULL,
            p_attribute7     => NULL,
            p_attribute8     => NULL,
            p_attribute9     => NULL,
            p_attribute10    => NULL,
            p_attribute11    => NULL,
            p_attribute12    => NULL,
            p_attribute13    => NULL,
            p_attribute14    => NULL,
            p_attribute15    => NULL,
            px_org_id        => l_org_id_tbl(j));
Line: 4122

         UPDATE ozf_resale_lines_int_all orli
         SET  resale_batch_id = l_resale_batch_id
         WHERE orli.sold_from_cust_account_id = l_sold_from_cust_id_tbl(j)
         AND   orli.org_id = l_org_id_tbl(j)
         AND   orli.currency_code = l_currency_code_tbl(j)
         AND   orli.request_id = G_CONC_REQUEST_ID;