518:
519: --
520: -- Here l_ddl contains the actual DECODE function.
521: -- we prepend and append the rest of the actual
522: -- rdbms CREATE INDEX command and pass to ad_ddl.
523: -- String overflow is still possible.
524: --
525: l_ddl := 'CREATE INDEX ' || g_qa_schema || '.' ||
526: '"' || p_index_name || '" ON ' ||
527: g_qa_schema || '.QA_RESULTS ' || p_alias ||
528: '(' || l_alias_dot || 'PLAN_ID, ' || l_ddl || ') ' ||
529: p_additional_parameters;
530:
531: ad_ddl.do_ddl(
532: applsys_schema => g_fnd_schema,
533: application_short_name => g_qa,
534: statement_type => ad_ddl.create_index,
535: statement => l_ddl,
530:
531: ad_ddl.do_ddl(
532: applsys_schema => g_fnd_schema,
533: application_short_name => g_qa,
534: statement_type => ad_ddl.create_index,
535: statement => l_ddl,
536: object_name => p_index_name);
537:
538: --
546: g_qa_schema || '.QA_RESULTS ' || p_alias ||
547: '(' || l_alias_dot || 'PLAN_ID, ' || l_num_index_ddl || ') ' ||
548: p_additional_parameters;
549:
550: ad_ddl.do_ddl(
551: applsys_schema => g_fnd_schema,
552: application_short_name => g_qa,
553: statement_type => ad_ddl.create_index,
554: statement => l_num_index_ddl,
549:
550: ad_ddl.do_ddl(
551: applsys_schema => g_fnd_schema,
552: application_short_name => g_qa,
553: statement_type => ad_ddl.create_index,
554: statement => l_num_index_ddl,
555: object_name => 'QA_'||p_char_id||'_INT');
556: END IF;
557:
708:
709: l_ddl := 'DROP INDEX ' || g_qa_schema || '.' ||
710: '"' || l_index_name || '"';
711:
712: ad_ddl.do_ddl(
713: applsys_schema => g_fnd_schema,
714: application_short_name => g_qa,
715: statement_type => ad_ddl.drop_index,
716: statement => l_ddl,
711:
712: ad_ddl.do_ddl(
713: applsys_schema => g_fnd_schema,
714: application_short_name => g_qa,
715: statement_type => ad_ddl.drop_index,
716: statement => l_ddl,
717: object_name => l_index_name);
718:
719: --
729: CLOSE c_num_idx;
730: l_ddl := 'DROP INDEX ' || g_qa_schema || '.' ||
731: '"' || l_num_int_index || '"';
732:
733: ad_ddl.do_ddl(
734: applsys_schema => g_fnd_schema,
735: application_short_name => g_qa,
736: statement_type => ad_ddl.drop_index,
737: statement => l_ddl,
732:
733: ad_ddl.do_ddl(
734: applsys_schema => g_fnd_schema,
735: application_short_name => g_qa,
736: statement_type => ad_ddl.drop_index,
737: statement => l_ddl,
738: object_name => l_num_int_index);
739: END IF;
740: END IF;