DBA Data[Home] [Help]

APPS.BIV_DASH_BIN_PKG SQL Statements

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

Line: 20

		l_select VARCHAR2(500);
Line: 39

  		l_select := 'INSERT INTO biv_tmp_bin (report_code, session_id, col2, col3, col4) ';
Line: 40

  		l_select := l_select || 'SELECT :report_id,:session_id,stat.name, ';
Line: 41

  		l_select := l_select || '''BIV_SERVICE_REQUEST';
Line: 43

                /* Parameters being added to l_url rather than l_select to accomadate
                   enhancement 2914005
                */
		if l_ogrp is not null then
			l_url := l_url || g_p_sp || 'P_OGRP' || g_v_sp || l_ogrp;
Line: 56

                l_select := l_select || l_url || g_p_sp || 'P_STS_ID' || g_v_sp;
Line: 57

                l_select := l_select || '''||stat.incident_status_id||''' || g_p_sp || '''';
Line: 58

                l_select := l_select || ',count(sr.incident_id) ';
Line: 68

		l_query := l_select  || ' ' || l_table || ' ' || l_where;
Line: 91

                  insert into biv_tmp_bin (report_code,session_id,col2,col4,col3) select biv_core_pkg.g_report_id,biv_core_pkg.get_session_id,
                                         l_total,decode(sum(col4),null,0,sum(col4)),l_totalurl from biv_tmp_bin;
Line: 109

	l_select VARCHAR2(1000);
Line: 144

	l_select := 'INSERT INTO biv_tmp_rt1(report_code,session_id,col2, col3, col4, ';
Line: 145

	l_select := l_select || 'col5, col6, col7, col8,col20) ';
Line: 146

	l_select := l_select || 'SELECT :l_report_code,:x_session_id,stat.name, ';
Line: 147

	l_select := l_select || '''BIV_RT_SR_SEV' || g_p_sp || 'jtfBinId';
Line: 148

	l_select := l_select || g_v_sp || 'BIV_RT_SR_SEV' || g_p_sp;
Line: 149

	l_select := l_select || 'P_CHNL' || g_v_sp || 'WEB' || g_p_sp;
Line: 150

	l_select := l_select || 'P_STS_ID' || g_v_sp || '''||';
Line: 151

	l_select := l_select || 'stat.incident_status_id||'''||l_url_param||''', ';
Line: 152

	l_select := l_select || 'sum(decode(upper(sr.sr_creation_channel),''WEB'',1,0)), ';
Line: 153

	l_select := l_select || '''BIV_RT_SR_SEV' || g_p_sp || 'jtfBinId';
Line: 154

	l_select := l_select || g_v_sp || 'BIV_RT_SR_SEV' || g_p_sp;
Line: 155

	l_select := l_select || 'P_CHNL' || g_v_sp || 'PHONE' || g_p_sp;
Line: 156

	l_select := l_select || 'P_STS_ID' || g_v_sp || '''||';
Line: 157

	l_select := l_select || 'stat.incident_status_id||'''||l_url_param||''', ';
Line: 158

	l_select := l_select || 'sum(decode(upper(sr.sr_creation_channel),''PHONE'',1,0)), ';
Line: 159

	l_select := l_select || '''BIV_RT_SR_SEV' || g_p_sp || 'jtfBinId';
Line: 160

	l_select := l_select || g_v_sp || 'BIV_RT_SR_SEV' || g_p_sp;
Line: 161

	l_select := l_select || 'P_ESC_SR' || g_v_sp || 'Y' || g_p_sp;
Line: 162

	l_select := l_select || 'P_STS_ID' || g_v_sp || '''||';
Line: 163

	l_select := l_select || 'stat.incident_status_id||'''||l_url_param||''', ';
Line: 164

	l_select := l_select || 'biv_dash_bin_pkg.get_esc_sr_backlog(1,stat.incident_status_id) ,''INDV_ROW''';
Line: 185

        g_esc_sel_stt := 'select count(sr.incident_id)
                         ' || g_esc_frm_lst || g_esc_whr_cls;
Line: 200

	l_query := l_select || ' ' || l_table || ' '|| l_where;
Line: 217

        select count(*) into l_ttl_recs
          from biv_tmp_rt1
         where report_code = l_report_code
           and session_id = g_session_id;
Line: 230

              biv_core_pkg.biv_debug('going to insert total row',
                                                              l_report_code);
Line: 233

           insert into biv_tmp_rt1 (report_code,session_id,
                                    col2,col4,col6,col8,col20,
                                    col3, col5, col7)
           select l_report_code, g_session_id, l_ttl_meaning, sum(col4),
                  sum(col6), sum(col8), 'TTL_ROW',
                  l_param_str || 'P_CHNL' || g_v_sp || 'WEB',
                  l_param_str || 'P_CHNL' || g_v_sp || 'PHONE',
                  l_param_str || 'P_ESC_SR' || g_v_sp || 'Y'
             from biv_tmp_rt1
            where report_code = l_report_code
              and session_id = g_session_id;
Line: 265

	l_select VARCHAR2(1000);
Line: 302

        l_select := l_select || 'INSERT INTO biv_tmp_rt1(report_code,session_id,col2,col3,col4,col5,col6) ';
Line: 303

        l_select := l_select || 'select :l_report_code,:g_session_id,c.NAME, ';
Line: 304

        l_select := l_select || '''BIV_SERVICE_REQUEST'||g_p_sp||'jtfBinId'||g_v_sp;
Line: 305

        l_select := l_select || 'BIV_SERVICE_REQUEST';
Line: 306

        l_select := l_select || g_p_sp||'P_ESC_SR'||g_v_sp||'Y'||g_p_sp||'P_STS_ID'||g_v_sp;
Line: 307

        l_select := l_select || l_status||g_p_sp||'P_SEV'||g_v_sp||'''||c.incident_severity_id||'''||l_url_param||''', ';
Line: 308

        l_select := l_select || ' count(sr.incident_id),';
Line: 309

        l_select := l_select || '''BIV_SERVICE_REQUEST'||g_p_sp||'jtfBinId'||g_v_sp;
Line: 310

        l_select := l_select || 'BIV_SERVICE_REQUEST';
Line: 311

        l_select := l_select || g_p_sp||'P_ESC_SR'||g_v_sp||'Y'||g_p_sp||'P_STS_ID'||g_v_sp;
Line: 312

        l_select := l_select || l_status||g_p_sp||'P_SEV'||g_v_sp||'''||c.incident_severity_id||'''||l_url_param||''', ';
Line: 313

        l_select := l_select || 'BIV_DASH_BIN_PKG.get_hours(min(sr.incident_date)) ';
Line: 338

        l_select := l_select || 'INSERT INTO biv_tmp_rt1(report_code,session_id,col2,col3,col4,col5,col6) ';
Line: 339

        l_select := l_select || 'select :l_report_code,:g_session_id,c.NAME, ';
Line: 340

        l_select := l_select || '''BIV_SERVICE_REQUEST'||g_p_sp||'jtfBinId'||g_v_sp;
Line: 341

        l_select := l_select || 'BIV_SERVICE_REQUEST';
Line: 342

        l_select := l_select || g_p_sp||'P_CHNL'||g_v_sp||l_channel||g_p_sp||'P_STS_ID'||g_v_sp;
Line: 343

        l_select := l_select || l_status||g_p_sp||'P_SEV'||g_v_sp||'''||c.incident_severity_id||'''||l_url_param||''', ';
Line: 344

        l_select := l_select || ' count(sr.incident_id), ';
Line: 345

        l_select := l_select || '''BIV_SERVICE_REQUEST'||g_p_sp||'jtfBinId'||g_v_sp;
Line: 346

        l_select := l_select || 'BIV_SERVICE_REQUEST';
Line: 347

        l_select := l_select || g_p_sp||'P_CHNL'||g_v_sp||l_channel||g_p_sp||'P_STS_ID'||g_v_sp;
Line: 348

        l_select := l_select || l_status||g_p_sp||'P_SEV'||g_v_sp||'''||c.incident_severity_id||'''||l_url_param||''', ';
Line: 349

        l_select := l_select || 'BIV_DASH_BIN_PKG.get_hours(min(sr.incident_date)) ';
Line: 370

	l_query := l_select || ' ' || l_table || ' '|| l_where;
Line: 409

    select attribute_label_long into l_report_name
    from ak_attributes_vl
    where attribute_code = 'P_SR_SEV_RPT_1';
Line: 415

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_3';
Line: 419

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_4';
Line: 423

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_5';
Line: 430

    select attribute_label_long into l_tmp
    from ak_attributes_vl
    where attribute_code = 'P_SR_SEV_RPT_2';
Line: 436

    SELECT name INTO l_tmp
    FROM cs_incident_statuses_vl
    WHERE incident_status_id = to_number(l_status);
Line: 455

    select attribute_label_long into l_label
    from ak_attributes_vl
    where attribute_code = 'P_SR_SEV_RPT_6';
Line: 461

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_3';
Line: 465

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_4';
Line: 469

        select attribute_label_long into l_tmp
        from ak_attributes_vl
        where attribute_code = 'P_SR_SEV_RPT_5';
Line: 476

    select attribute_label_long into l_tmp
    from ak_attributes_vl
    where attribute_code = 'P_SR_SEV_RPT_7';
Line: 482

    SELECT name INTO l_tmp
    FROM cs_incident_statuses_vl
    WHERE incident_status_id = to_number(l_status);
Line: 489

    select attribute_label_long into l_tmp
    from ak_attributes_vl
    where attribute_code = 'P_SR_SEV_RPT_8';
Line: 504

    select count(ina.incident_id) into x_val
    FROM
        cs_incidents_all_b ina,
        jtf_task_references_b r, jtf_tasks_b t
    WHERE ina.incident_id = r.object_id
          and r.task_id      = t.task_id
          and r.object_type_code = 'SR'
          and r.reference_code   = 'ESC'
          and t.task_type_id     = 22
          and t.escalation_level is not null
          and ina.incident_status_id = p_status;
Line: 541

    select decode(count(*),0,'N','Y') into x_esc_flag
    from jtf_task_references_b r,jtf_tasks_b t
    where r.OBJECT_ID = p_sr_id
    and r.object_type_code = 'SR'
    and r.reference_code   = 'ESC'
    and r.task_id          = t.task_id
    and t.task_type_id     = 22;