SELECT va.application_name,
a.user_concurrent_program_name AS user_concurrent_program_name,
va.execution_file_name short_name,
va.executable_name executable_name,
NVL ((SELECT ---LOB_CODE,
file_name
FROM xdo_lobs
WHERE application_short_name = 'XXCUS'
AND xdo_file_type = 'RTF'
AND UPPER (lob_code) = UPPER (va.executable_name)),
'NOT RTF'
) rtf_name,
a.concurrent_program_name AS concurrent_program_name,
DECODE (a.execution_method_code,
'P', 'Oracel Report',
'I', 'PL/SQL Stored Procedure',
a.execution_method_code
) report_type,
a.output_file_type, a.output_print_style,
c.application_short_name AS application_short_name,
b.column_seq_num AS column_seq_num, b.srw_param AS param_seq,
d.flex_value_set_name AS values_set_name,
'Select '
||CHR(10)||FVT.VALUE_COLUMN_NAME||' VALUE ' ||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' ,'
||CHR(10)||FVT.MEANING_COLUMN_NAME||' MEANING '||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' ,'
||CHR(10)||FVT.ID_COLUMN_NAME||' ID '||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' '
||CHR(10)||' From '||FVT.APPLICATION_TABLE_NAME "SELECT_FROM" ,
FVT.ADDITIONAL_WHERE_CLAUSE "Where",
FVT.ADDITIONAL_QUICKPICK_COLUMNS ADDITIONAL_COLUMN,
DECODE (b.default_type,
'S', 'SQL Statement',
'P', 'Profile'
) default_type,
b.DEFAULT_VALUE,
DECODE (b.required_flag, 'Y', 'YES', 'N', 'NO') required_type,
DECODE (b.display_flag, 'Y', 'YES', 'N', 'NO') display_type,
b.form_left_prompt AS prompt
FROM fnd_concurrent_programs_vl a,
fnd_descr_flex_col_usage_vl b,
fnd_application c,
fnd_flex_value_sets d,
fnd_executables_form_v va, FND_FLEX_VALIDATION_TABLES FVT
WHERE a.enabled_flag = 'Y'
AND a.application_id = va.application_id
AND TRIM (va.executable_name) = TRIM (a.concurrent_program_name)
AND a.concurrent_program_name =
SUBSTR (b.descriptive_flexfield_name, 7, 100)
AND a.application_id = c.application_id
AND b.enabled_flag = 'Y'
and va.execution_file_name like '%XX%'
AND b.flex_value_set_id = d.flex_value_set_id
AND b.flex_value_set_id = fvt.flex_value_set_id (+)
AND a.application_id = 20003 --(Your Application Id)
ORDER BY a.concurrent_program_id, b.column_seq_num, 1;
a.user_concurrent_program_name AS user_concurrent_program_name,
va.execution_file_name short_name,
va.executable_name executable_name,
NVL ((SELECT ---LOB_CODE,
file_name
FROM xdo_lobs
WHERE application_short_name = 'XXCUS'
AND xdo_file_type = 'RTF'
AND UPPER (lob_code) = UPPER (va.executable_name)),
'NOT RTF'
) rtf_name,
a.concurrent_program_name AS concurrent_program_name,
DECODE (a.execution_method_code,
'P', 'Oracel Report',
'I', 'PL/SQL Stored Procedure',
a.execution_method_code
) report_type,
a.output_file_type, a.output_print_style,
c.application_short_name AS application_short_name,
b.column_seq_num AS column_seq_num, b.srw_param AS param_seq,
d.flex_value_set_name AS values_set_name,
'Select '
||CHR(10)||FVT.VALUE_COLUMN_NAME||' VALUE ' ||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' ,'
||CHR(10)||FVT.MEANING_COLUMN_NAME||' MEANING '||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' ,'
||CHR(10)||FVT.ID_COLUMN_NAME||' ID '||
Decode (VALUE_COLUMN_TYPE, 'C', 'CHR', 'N', 'NUMBER', 'V', 'VARCHAR2', 'D', 'Date') ||
' Size '||VALUE_COLUMN_SIZE ||' '
||CHR(10)||' From '||FVT.APPLICATION_TABLE_NAME "SELECT_FROM" ,
FVT.ADDITIONAL_WHERE_CLAUSE "Where",
FVT.ADDITIONAL_QUICKPICK_COLUMNS ADDITIONAL_COLUMN,
DECODE (b.default_type,
'S', 'SQL Statement',
'P', 'Profile'
) default_type,
b.DEFAULT_VALUE,
DECODE (b.required_flag, 'Y', 'YES', 'N', 'NO') required_type,
DECODE (b.display_flag, 'Y', 'YES', 'N', 'NO') display_type,
b.form_left_prompt AS prompt
FROM fnd_concurrent_programs_vl a,
fnd_descr_flex_col_usage_vl b,
fnd_application c,
fnd_flex_value_sets d,
fnd_executables_form_v va, FND_FLEX_VALIDATION_TABLES FVT
WHERE a.enabled_flag = 'Y'
AND a.application_id = va.application_id
AND TRIM (va.executable_name) = TRIM (a.concurrent_program_name)
AND a.concurrent_program_name =
SUBSTR (b.descriptive_flexfield_name, 7, 100)
AND a.application_id = c.application_id
AND b.enabled_flag = 'Y'
and va.execution_file_name like '%XX%'
AND b.flex_value_set_id = d.flex_value_set_id
AND b.flex_value_set_id = fvt.flex_value_set_id (+)
AND a.application_id = 20003 --(Your Application Id)
ORDER BY a.concurrent_program_id, b.column_seq_num, 1;