DBA Data[Home] [Help]

APPS.CSR_SCHEDULER_PVT SQL Statements

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

Line: 78

      SELECT l.location_id
           , l.geometry
           , l.house_number
           , l.address1
           , l.address2
           , l.address3
           , l.address4
           , l.city
           , l.state
           , l.postal_code
           , fnd.territory_short_name country
           , l.country country_code
        FROM jtf_tasks_b t
           , hz_locations l
           , fnd_territories_vl fnd
       WHERE t.task_id = p_task_id
         AND l.location_id = csf_tasks_pub.get_task_location_id(t.task_id, t.address_id, t.location_id)
         AND fnd.territory_code = l.country;
Line: 212

      SELECT MIN(timezone_id)
        INTO l_timezone_id
        FROM hz_timezones
       WHERE gmt_deviation_hours = -8
         AND daylight_savings_time_flag = 'Y';
Line: 253

      SELECT loc.timezone_id
        FROM hz_party_sites par
           , hz_locations loc
       WHERE par.party_site_id = p_address_id
         AND par.location_id = loc.location_id;
Line: 378

      SELECT planned_start_date
           , planned_end_date
           , source_object_id
        FROM jtf_tasks_b
       WHERE task_id = p_task_id;
Line: 574

      SELECT t.task_id
           , t.planned_start_date
           , t.planned_end_date
           , t.source_object_id
        FROM jtf_tasks_b t
       WHERE t.task_id = p_task_id;
Line: 700

      SELECT rt.request_task_id
           , t.task_id
           , t.source_object_id
           , t.planned_start_date
           , t.planned_end_date
        FROM (  SELECT sched_request_id
                  FROM csf_r_sched_requests
                 WHERE parent_request_id = p_request_id
                UNION ALL
                SELECT sched_request_id
                  FROM csf_r_sched_requests
                 WHERE sched_request_id = p_request_id
                   AND NOT EXISTS (SELECT 1
                                     FROM csf_r_sched_requests
                                    WHERE parent_request_id = p_request_id)
             ) r
           , csf_r_request_tasks rt
           , jtf_tasks_b t
       WHERE rt.sched_request_id = r.sched_request_id
         AND NOT EXISTS ( SELECT 1
                            FROM csf_r_resource_results rr
                           WHERE rr.request_task_id = rt.request_task_id
                         )
         AND t.task_id = rt.task_id;
Line: 927

    l_stmt := 'SELECT task_id FROM csf_ct_tasks WHERE ' || l_where || ' ORDER BY scheduled_start_date NULLS FIRST, planned_end_date, creation_date';
Line: 988

      SELECT /*+ cardinality(t, 1) */ DISTINCT tr.resource_id, tr.resource_type
        FROM jtf_terr_rsc_all tr
           , TABLE( CAST ( csf_util_pvt.get_selected_terr_table AS jtf_number_table ) ) t
       WHERE tr.terr_id = t.column_value
         AND (p_terr_id IS NULL OR tr.terr_id = p_terr_id);
Line: 1076

      SELECT source_object_id
        FROM jtf_tasks_b t
           , TABLE( CAST ( p_task_id_tbl AS jtf_number_table ) ) tt
       WHERE t.task_id = tt.COLUMN_VALUE;
Line: 1136

      l_task_res_tbl.DELETE;
Line: 1186

      SELECT 'Y'
        FROM csp_req_line_details crld
           , csp_requirement_lines crl
           , csp_requirement_headers crh
       WHERE crh.task_assignment_id = p_task_assignment_id
         AND crl.requirement_header_id = crh.requirement_header_id
         AND crld.requirement_line_id = crl.requirement_line_id
         AND crld.source_type = 'RES' ;
Line: 1196

      SELECT 'Y'
        FROM csp_req_line_details crld
           , csp_requirement_lines crl
           , csp_requirement_headers crh
           , oe_order_lines_all oel
           , oe_order_headers_all oeh
       WHERE crh.task_assignment_id = p_task_assignment_id
         AND crl.requirement_header_id = crh.requirement_header_id
         AND crld.requirement_line_id = crl.requirement_line_id
         AND crld.source_type = 'IO'
         AND oel.line_id = crld.source_id
         AND oeh.header_id =  oel.header_id
         AND oeh.flow_status_code <>'CANCELLED'
       ORDER BY oeh.header_id;
Line: 1255

      SELECT t.task_id
           , ta.task_assignment_id
           , ah.access_hour_id
           , oc.object_capacity_id
        FROM jtf_tasks_b t
           , jtf_task_assignments ta
           , jtf_task_statuses_b ts
           , csf_access_hours_b ah
           , cac_sr_object_capacity oc
           , TABLE ( CAST ( p_resource_tbl AS CSF_RESOURCE_TBL ) ) r
       WHERE t.task_id = ta.task_id
         AND ta.assignment_status_id = ts.task_status_id
         AND t.task_id = ah.task_id(+)
         AND ta.resource_id = oc.object_id
         AND ta.resource_type_code = oc.object_type
         AND (
                 (     ta.object_capacity_id IS NOT NULL
                   AND ta.object_capacity_id = oc.object_capacity_id
                 )
              OR (
                       ta.object_capacity_id IS NULL
                   AND ta.booking_start_date < oc.end_date_time
                   AND ta.booking_end_date > oc.start_date_time
                 )
             )
         AND t.scheduled_end_date >= t.scheduled_start_date
         AND (t.deleted_flag = 'N' OR t.deleted_flag IS NULL)
         AND (
                 NVL(ta.actual_start_date, ta.actual_end_date) IS NOT NULL
              OR ((ts.cancelled_flag = 'N' OR ts.cancelled_flag IS NULL))
             )
         AND oc.object_id = r.resource_id
         AND oc.object_type = r.resource_type
         AND oc.start_date_time <= r.planwin_end
         AND oc.end_date_time >= r.planwin_start
         FOR UPDATE OF t.task_id, ta.task_assignment_id, ah.access_hour_id, oc.object_capacity_id NOWAIT;