DBA Data[Home] [Help]

APPS.GMS_SUMMARIZE_BUDGETS SQL Statements

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

Line: 32

         select start_date_active ,
                NVL(end_date_active, SYSDATE) ,
                entry_level_code,categorization_code,
                time_phased_type_code,
                burdened_cost_flag
          into l_start_date_active,
               l_end_date_active,
               l_entry_level_code,
               l_categorization_code,
               l_time_phased_type_code,
               l_burdened_cost_flag
          from  pa_budget_entry_methods
         where  BUDGET_ENTRY_METHOD = p_project_bem ;
Line: 114

    select count(distinct budget_entry_method_code) ,
           count(distinct resource_list_id ), count(distinct award_id)
      into l_bem_count, l_res_list_count, l_award_count
      from GMS_BUDGET_VERSIONS
     where budget_status_code = 'B'
      and current_flag = 'Y'
      and project_id = x_project_id ;
Line: 165

         select distinct rl.name
           into l_res_list_name
           from GMS_BUDGET_VERSIONS gb ,  pa_resource_lists  rl
          where gb.resource_list_id = rl.resource_list_id
            and budget_status_code = 'B'
            and current_flag = 'Y'
            and project_id = x_project_id ;
Line: 195

        select distinct time_phased_type_code  -- Added distinct for bug : 5750106
          into l_time_phased_type_code
          from GMS_BUDGET_VERSIONS bv,  pa_budget_entry_methods bem
         where bv.budget_entry_method_code = bem.budget_entry_method_code
           and bv.project_id = x_project_id ;
Line: 262

        select distinct resource_list_id
          into  G_pa_res_list_id
          from GMS_BUDGET_VERSIONS
         where budget_status_code = 'B'
           and current_flag = 'Y'
           and project_id = x_project_id ;
Line: 277

        select resource_list_id
          into G_pa_res_list_id_none
          from pa_resource_lists prl , pa_implementations pai
         where prl.business_group_id = pai.business_group_id
           and prl.uncategorized_flag = 'Y'
           and NVL(prl.migration_code ,'M') = 'M' ;
Line: 292

  select distinct   gbl.start_date
  ,      gbl.end_date
  from   gms_budget_versions            gbv
  ,      gms_resource_assignments       gra
  ,      gms_budget_lines               gbl
  where  gbv.budget_version_id = gra.budget_version_id
  and    gra.resource_assignment_id = gbl.resource_assignment_id
  and    gbv.project_id = p_project_id
  and    gra.resource_list_member_id = p_resource_list_member_id;
Line: 304

  select distinct gra.resource_list_member_id , gbl.start_date
  ,      gbl.end_date
  from   gms_budget_versions            gbv
  ,      gms_resource_assignments       gra
  ,      gms_budget_lines               gbl
  where  gbv.budget_version_id = gra.budget_version_id
  and    gra.resource_assignment_id = gbl.resource_assignment_id
  and    gbv.project_id = p_project_id
  and    gbv.current_flag = 'Y'
  order by gra.resource_list_member_id ;-- , award_id ;
Line: 322

     select count(award_id)
        into l_award_count
      from GMS_BUDGET_VERSIONS
     where budget_status_code = 'B'
      and current_flag = 'Y'
      and project_id = x_project_id;
Line: 421

    	select  distinct gbv.resource_list_id -- Added distinct for Bug:2254944
    	, 	gbv.budget_entry_method_code , bem.time_phased_type_code  -- Added time_phase_type_code for bug: 5750106
	into	x_resource_list_id
	, 	x_budget_entry_method_code,l_time_phased_type_code
      	from 	gms_budget_versions gbv, pa_budget_entry_methods bem
 	where 	gbv.project_id = x_project_id
          and gbv.budget_entry_method_code = bem.budget_entry_method_code -- Added for bug 5750106
	and	gbv.current_flag = 'Y';
Line: 505

     Select 	1
     into	draft_budget_check
     from	pa_budget_versions
     where	project_id = x_project_id
     and	budget_type_code = 'AC'
     and 	budget_status_code in ('W', 'S');
Line: 587

   select	gbl.period_name
   ,            decode(p_res_grp,
                       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id) resource_list_member_id
   ,	 	gra.task_id
   ,	 	sum(gbl.raw_cost) raw_cost
   ,	 	sum(gbl.burdened_cost) burdened_cost
   ,	 	sum(gbl.quantity) quantity
   from 	gms_budget_versions 	gbv
   , 	 	gms_resource_assignments gra
   ,	 	gms_budget_lines 	gbl
   ,		pa_resource_list_members prl --> Bug 2935048
   where 	gbv.project_id = x_project_id
   and	 	gbv.budget_version_id = gra.budget_version_id
   and	 	gra.resource_assignment_id = gbl.resource_assignment_id
   and	 	gbv.current_flag = 'Y'
   and          gbv.resource_list_id = prl.resource_list_id
   and          gra.resource_list_member_id = prl.resource_list_member_id
   and          gra.task_id = p_task_id
   group  by 	gbl.period_name,
                decode(p_res_grp,
                       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id),
                 gra.task_id;
Line: 616

   select	gbl.start_date
   , 		gbl.end_date
   ,            decode(p_res_grp,
                       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id) resource_list_member_id
   ,	 	gra.task_id
   ,	 	sum(gbl.raw_cost) raw_cost
   ,	 	sum(gbl.burdened_cost) burdened_cost
   ,	 	sum(gbl.quantity) quantity
   from 	gms_budget_versions 	gbv
   , 	 	gms_resource_assignments gra
   ,	 	gms_budget_lines 	gbl
   ,            pa_resource_list_members prl --> Bug 2935048
   where 	gbv.project_id = x_project_id
   and	 	gbv.budget_version_id = gra.budget_version_id
   and	 	gra.resource_assignment_id = gbl.resource_assignment_id
   and	 	gbv.current_flag = 'Y'
   and          gbv.resource_list_id = prl.resource_list_id
   and          gra.resource_list_member_id = prl.resource_list_member_id
   and          gra.task_id = p_task_id
   group  by 	gbl.start_date, gbl.end_date,
                decode(p_res_grp,
                       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id),
                gra.task_id;
Line: 646

   select       decode(p_res_grp,
		       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id) resource_list_member_id
   ,            gra.task_id
   ,            sum(gbl.raw_cost) raw_cost
   ,            sum(gbl.burdened_cost) burdened_cost
   ,            sum(gbl.quantity) quantity
   from         gms_budget_versions     gbv
   ,            gms_resource_assignments gra
   ,            gms_budget_lines        gbl
   ,            pa_resource_list_members prl --> Bug 2935048
   where        gbv.project_id = x_project_id
   and          gbv.budget_version_id = gra.budget_version_id
   and          gra.resource_assignment_id = gbl.resource_assignment_id
   and          gbv.current_flag = 'Y'
   and          gbv.resource_list_id = prl.resource_list_id
   and          gra.resource_list_member_id = prl.resource_list_member_id
   and          gra.task_id = p_task_id
   group  by    decode(p_res_grp,
                       'Y', nvl(prl.parent_member_id, gra.resource_list_member_id),
                       gra.resource_list_member_id),
                gra.task_id;
Line: 670

    select distinct gra.task_id
      from gms_resource_assignments gra,
           gms_budget_versions gbv
     where gra.project_id = x_project_id
       and gra.project_id = gbv.project_id
       and gbv.current_flag = 'Y'
       and gbv.budget_status_code = 'B';
Line: 729

    select 'Y'
      into v_mixed_level_budget
      from dual
     where exists (select '1'
                     from pa_resource_list_members prl,
                          gms_resource_assignments gra,
                          gms_budget_versions gbv
                    where prl.resource_list_id = x_resource_list_id
                      and prl.resource_list_member_id = gra.resource_list_member_id
                      and gbv.budget_version_id = gra.budget_version_id
                      and gbv.current_flag = 'Y'
                      and prl.parent_member_id is null
                      and gra.project_id = x_project_id
                      and gra.task_id = x_task_id);
Line: 755

   select        prl.resource_list_member_id ,
                gbv.project_id ,
                sum(gbl.raw_cost) raw_cost
   ,            sum(gbl.burdened_cost) burdened_cost
   ,            sum(gbl.quantity) quantity
   from         gms_budget_versions     gbv
   ,            gms_resource_assignments gra
   ,            gms_budget_lines        gbl
   ,            pa_resource_list_members prl
   where        gbv.project_id = x_project_id
   and          gbv.budget_version_id = gra.budget_version_id
   and          gra.resource_assignment_id = gbl.resource_assignment_id
   and          gbv.current_flag = 'Y'
   and          G_pa_res_list_id_none = prl.resource_list_id
   and          gra.resource_list_member_id = prl.resource_list_member_id
   group by     prl.resource_list_member_id , gbv.project_id;
Line: 774

   select
                gra.resource_list_member_id ,
            gbv.project_id
   ,            sum(gbl.raw_cost) raw_cost
   ,            sum(gbl.burdened_cost) burdened_cost
   ,            sum(gbl.quantity) quantity
   from         gms_budget_versions     gbv
   ,            gms_resource_assignments gra
   ,            gms_budget_lines        gbl
   ,            pa_resource_list_members prl
   where        gbv.project_id = x_project_id
   and          gbv.budget_version_id = gra.budget_version_id
   and          gra.resource_assignment_id = gbl.resource_assignment_id
   and          gbv.current_flag = 'Y'
   and          gbv.resource_list_id = prl.resource_list_id
   and          gra.resource_list_member_id = prl.resource_list_member_id
   group by    gra.resource_list_member_id, gbv.project_id ;
Line: 795

  select distinct gra.resource_list_member_id , gbl.start_date
  ,      gbl.end_date
  from   gms_budget_versions            gbv
  ,      gms_resource_assignments       gra
  ,      gms_budget_lines               gbl
  where  gbv.budget_version_id = gra.budget_version_id
  and    gra.resource_assignment_id = gbl.resource_assignment_id
  and    gbv.project_id = p_project_id
  and    gbv.current_flag = 'Y'
  order by gra.resource_list_member_id ;
Line: 809

  select distinct   gbl.start_date
  ,      gbl.end_date
  from   gms_budget_versions            gbv
  ,      gms_resource_assignments       gra
  ,      gms_budget_lines               gbl
  where  gbv.budget_version_id = gra.budget_version_id
  and    gra.resource_assignment_id = gbl.resource_assignment_id
  and    gbv.project_id = p_project_id
  and    gra.resource_list_member_id = p_resource_list_member_id;
Line: 823

            SELECT start_date,
                   completion_date
            INTO   x_project_start_date,
                   x_project_end_date
            FROM   pa_projects_all
            WHERE  project_id = x_project_id;
Line: 923

                      SELECT profile_option_value
                      INTO   l_user_profile_value1
                      FROM   fnd_profile_options       p,
                             fnd_profile_option_values v
                      WHERE  p.profile_option_name = 'PA_SUPER_PROJECT'
                      AND    v.profile_option_id = p.profile_option_id
                      AND    v.level_id = 10004
                      AND    v.level_value = fnd_global.user_id;
Line: 948

                      SELECT profile_option_value
                      INTO   l_user_profile_value2
                      FROM   fnd_profile_options       p,
                             fnd_profile_option_values v
                      WHERE  p.profile_option_name = 'PA_SUPER_PROJECT_VIEW'
                      AND    v.profile_option_id = p.profile_option_id
                      AND    v.level_id = 10004
                      AND    v.level_value = fnd_global.user_id;
Line: 969

      SELECT start_date,
             completion_date
      INTO   x_project_start_date,
             x_project_end_date
      FROM   pa_projects_all
      WHERE  project_id = x_project_id;
Line: 982

	   gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - Calling pa_budget_pub.delete_draft_budget','C');
Line: 985

        pa_budget_pub.delete_draft_budget(p_api_version_number => 1.0
				         ,p_init_msg_list => 'T'
					 ,p_msg_count => x_msg_count
					 ,p_msg_data => x_err_stage
					 ,p_return_status => x_return_status
					 ,p_pm_product_code => 'GMS' -- bug 3175909
					 ,p_pa_project_id => x_project_id
					 ,p_budget_type_code => 'AC');
Line: 1004

	    	gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - after delete draft; **************************','C');
Line: 1005

	    	gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - after delete draft; x_return_status = '||x_return_status,'C');
Line: 1006

	    	gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - after delete draft; x_err_stage = '||x_err_stage,'C');
Line: 1007

	    	gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - after delete draft; x_msg_count = '||x_msg_count,'C');
Line: 1008

	    	gms_error_pkg.gms_debug('GMS_SUMMARIZE_BUDGETS.SUMMARIZE_BASELINED_VERSIONS - after delete draft; **************************','C');
Line: 1083

	   SELECT 	nvl(start_date,x_project_start_date),
        	        nvl(completion_date,x_project_end_date)
             INTO  x_task_start_date,
                   x_task_end_date  /* Changed for bug 3372853 */
             FROM  pa_tasks
            WHERE  task_id = v_task_id;
Line: 1145

            SELECT start_date,
                   completion_date
            INTO   x_project_start_date,
                   x_project_end_date
            FROM   pa_projects_all
            WHERE  project_id = x_project_id;
Line: 1159

	      SELECT distinct entry_level_code -- Added DISTINCT for Bug:2907692
	        INTO x_entry_level_code
	        FROM pa_budget_entry_methods pbem,
		     gms_budget_versions gbv
	       WHERE gbv.budget_entry_method_code = pbem.budget_entry_method_code
	         AND gbv.project_id = x_project_id
	         AND gbv.budget_status_code = 'B'
	         AND gbv.current_flag = 'Y';
Line: 1170

	        SELECT 	nvl(start_date,x_project_start_date),
               		nvl(completion_date,x_project_end_date)
         	  INTO  x_task_start_date,
                	x_task_end_date  /* Changed for bug 3372853 */
         	  --INTO x_project_start_date,
                  --     x_project_end_date
         	  FROM  pa_tasks
         	 WHERE 	task_id = rec_c3.task_id;
Line: 1239

      select budget_entry_method_code
        into x_entry_method_code
        from pa_budget_entry_methods
    where budget_entry_method = G_project_bem ;
Line: 1272

			l_budget_lines_in.delete(j);