add

About Me

My photo
Oracle Apps - Techno Functional consultant

Tuesday, June 21

Concurrent Program Backend Registration Code

-- Program Name:
-- Creation Date:
-- Version:
-- Description: Register the Program ZENSI GL Journal Entry Interface (Loader and Validation)
-- Author: RAJU.CH
--
-- Version History:
-- Date Version Author Descrip
-- -------- ----------- ---------------- ------------------------
-- 19-12-11 1.1 Change the Spelling of Journal in the message display in the
-- executable creation part and in program creation part.
SET SERVEROUTPUT ON
SET VERIFY OFF

DECLARE
v_param_flag VARCHAR2 (1);
v_appl_name VARCHAR2 (240) := '&1';
v_base_path VARCHAR2 (240) := '&2';
BEGIN
BEGIN
fnd_program.set_session_mode ('seed_data');
END;

-----------------------------
--- Create Executable ---
-----------------------------
BEGIN
IF fnd_program.executable_exists (
executable_short_name => 'ZENGLJEINT',
application => v_appl_name)
THEN
--DBMS_OUTPUT.PUT_LINE('EXISTS');
NULL;
ELSE
fnd_program.executable (
executable => 'ZENGLJEINT',
short_name => 'ZENGLJEINT',
application => 'EAG Customization',
description => 'ZENSI GL Journal Entry Interface (Loader and Validation)',
execution_method => 'Host',
execution_file_name => 'ZENGLJEINT',
subroutine_name => NULL,
ICON_NAME => NULL,
LANGUAGE_CODE => 'US',
EXECUTION_FILE_PATH => NULL);
END IF;
EXCEPTION
WHEN OTHERS
THEN
RAISE;
END;

-----------------------------
--- Create Program ---
-----------------------------
BEGIN
IF fnd_program.program_exists (program => 'ZENGLJEINT',
application => 'Oracle General Ledger')
THEN
DBMS_OUTPUT.PUT_LINE ('EXISTS');
ELSE
fnd_program.register (
program => 'ZENSI GL Journal Entry Interface (Loader and Validation)',
application => 'Oracle General Ledger',
enabled => 'Y',
short_name => 'ZENGLJEINT',
description => 'ZENSI GL Journal Entry Interface (Loader and Validation)',
executable_short_name => 'ZENGLJEINT',
executable_application => 'Oracle General Ledger',
priority => NULL,
save_output => 'Y',
PRINT => 'N',
cols => 132,
rows => 45,
style => 'Landscape',
style_required => 'N',
printer => '',
use_in_SRS => 'Y',
allow_disabled_values => 'N',
run_alone => 'N',
enable_trace => 'N',
restart => 'Y',
nls_compliant => 'Y',
output_type => 'Text',
execution_options => NULL,
request_type => NULL,
request_type_application => NULL,
icon_name => NULL,
language_code => 'US',
mls_function_short_name => NULL,
mls_function_application => NULL,
incrementor => NULL);

---------------------------------------------
--- Create Program Parameters(1) ---
---------------------------------------------
BEGIN
SELECT DISTINCT 'Y'
INTO v_param_flag
FROM fnd_flex_value_sets
WHERE flex_value_set_name = 'FND_CHAR240';

fnd_program.parameter (
program_short_name => 'ZENGLJEINT',
application => 'Oracle General Ledger',
sequence => 1,
parameter => 'File Path Name',
description => 'File Path Name',
enabled => 'Y',
value_set => 'FND_CHAR240',
default_type => '',
DEFAULT_VALUE => '',
required => 'Y',
enable_security => 'N',
range => '',
display => 'Y',
display_size => 30,
description_size => 50,
concatenated_description_size => 25,
prompt => 'File Path Name',
token => '');
EXCEPTION
WHEN NO_DATA_FOUND
THEN
--DBMS_OUTPUT.PUT_LINE('Value Set: FND_CHAR240 Not Defined');
RAISE;
END;

---------------------------------------------

--- Create Program Parameters(2) ---
---------------------------------------------
BEGIN
SELECT DISTINCT 'Y'
INTO v_param_flag
FROM fnd_flex_value_sets
WHERE flex_value_set_name = 'FND_CHAR240';

fnd_program.parameter (
program_short_name => 'ZENGLJEINT',
application => 'Oracle General Ledger',
sequence => 2,
parameter => 'Base Path',
description => 'Base Path',
enabled => 'Y',
value_set => 'FND_CHAR240',
default_type => 'Constant',
DEFAULT_VALUE => v_base_path,
required => 'Y',
enable_security => 'N',
range => '',
display => 'Y',
display_size => 15,
description_size => 50,
concatenated_description_size => 25,
prompt => 'Base Path',
token => '');
EXCEPTION
WHEN NO_DATA_FOUND
THEN
--DBMS_OUTPUT.PUT_LINE('Value Set: FND_CHAR240 Not Defined');
RAISE;
END;

---------------------------------------------

--- Create Program Parameters(3) ---
---------------------------------------------
BEGIN
SELECT DISTINCT 'Y'
INTO v_param_flag
FROM fnd_flex_value_sets
WHERE flex_value_set_name = 'FND_NUMBER15_REQUIRED';

fnd_program.parameter (
program_short_name => 'ZENGLJEINT',
application => 'Oracle General Ledger',
sequence => 3,
parameter => 'Set Of Book Id',
description => 'Set Of Book Id',
enabled => 'Y',
value_set => 'FND_NUMBER15_REQUIRED',
default_type => 'Profile',
DEFAULT_VALUE => 'GL_SET_OF_BKS_ID',
required => 'Y',
enable_security => 'N',
range => '',
display => 'N',
display_size => 15,
description_size => 50,
concatenated_description_size => 25,
prompt => 'Set Of Book Id',
token => '');
EXCEPTION
WHEN NO_DATA_FOUND
THEN
--DBMS_OUTPUT.PUT_LINE('Value Set: FND_NUMBER15_REQUIRED Not Defined');
RAISE;
END;

---------------------------------------------

--- Create Program Parameters(4) ---
---------------------------------------------
BEGIN
SELECT DISTINCT 'Y'
INTO v_param_flag
FROM fnd_flex_value_sets
WHERE flex_value_set_name = 'GL_SRS_JOURNAL_SOURCE';

fnd_program.parameter (
program_short_name => 'ZENGLJEINT',
application => 'Oracle General Ledger',
sequence => 4,
parameter => 'JE Batch Source Name',
description => 'JE Batch Source Name',
enabled => 'Y',
value_set => 'GL_SRS_JOURNAL_SOURCE',
default_type => '',
DEFAULT_VALUE => '',
required => 'Y',
enable_security => 'N',
range => '',
display => 'Y',
display_size => 25,
description_size => 50,
concatenated_description_size => 25,
prompt => 'JE Batch Source Name',
token => '');
EXCEPTION
WHEN NO_DATA_FOUND
THEN
--DBMS_OUTPUT.PUT_LINE('Value Set: GL_SRS_JOURNAL_SOURCE Not Defined');
RAISE;
END;

---------------------------------------------

--- Create Program Parameters(4) ---
---------------------------------------------
BEGIN
SELECT DISTINCT 'Y'
INTO v_param_flag
FROM fnd_flex_value_sets
WHERE flex_value_set_name = 'FND_NUMBER15';

fnd_program.parameter (
program_short_name => 'ZENGLJEINT',
application => 'Oracle General Ledger',
sequence => 5,
parameter => 'Group Id',
description => 'Group Id',
enabled => 'Y',
value_set => 'FND_NUMBER15',
default_type => 'Constant',
DEFAULT_VALUE => '9999',
required => 'Y',
enable_security => 'N',
range => '',
display => 'Y',
display_size => 15,
description_size => 50,
concatenated_description_size => 25,
prompt => 'Group Id',
token => '');
EXCEPTION
WHEN NO_DATA_FOUND
THEN
--DBMS_OUTPUT.PUT_LINE('Value Set: FND_NUMBER15 Not Defined');
RAISE;
END;

--DBMS_OUTPUT.PUT_LINE('Program ZENSI GL Journal Entry Interface (Loader and Validation) Successfully Created');
DBMS_OUTPUT.PUT_LINE ('SUCCESS');
END IF;
EXCEPTION
WHEN OTHERS
THEN
RAISE;
END;

COMMIT;
EXCEPTION
WHEN OTHERS
THEN
ROLLBACK;
--DBMS_OUTPUT.PUT_LINE('SQL Error: Program Terminated: Rollback Complete');
END;
/

No comments: