xxen_upload
Routines an upload package and its SQL call during a Blitz Upload run.
Summary
| Routine | Description |
|---|---|
| action_meaning | Returns the translated display value of an upload action code (C create, U update, D delete), as shown in the Action column; the code itself when it has no translation. |
| status_meaning | Returns the translated display value of an upload status code (N new, V valid, I invalid, E error, W warning, S success), as shown in the Status column; the code itself when it has no translation. |
| action_create | Returns the action code for create (C), for SQL, which cannot reference package constants. |
| action_update | Returns the action code for update (U). |
| action_delete | Returns the action code for delete (D). |
| status_new | Returns the status code new (N). |
| status_valid | Returns the status code valid (V). |
| status_invalid | Returns the status code invalid (I). |
| status_error | Returns the status code error (E). |
| status_warning | Returns the status code warning (W). |
| status_success | Returns the status code success (S). |
| run_id | Returns the run id of the upload being processed, the key of its rows in xxen_upload_data and of its run in xxen_report_runs. |
| property | Returns a custom document property of the uploaded workbook, for example xxen_run_id, the run id of the download that created it, or xxen_template_id; null when the file does not carry it, such as a csv file. |
| submit_upload_process | Submits the upload of a workbook stored in fnd_lobs (p_file_id) as a concurrent request for the upload p_report_name with template p_template_name. |
| attach_source_file | Attaches the uploaded file to an EBS record as a File attachment, for example to the journal or invoice the upload created. |
| check_and_add_attachment | Adds an attachment to an EBS record unless an identical one exists. |
| parameter_exists | True when the upload procedure parameter p_parameter_name (lower case) is mapped to a column of the uploaded file. |
| read_only | True when the column of the parameter p_parameter_name (lower case) is read only in the upload or its template. |
| value_modified_ | Y when the user modified the column of parameter p_parameter_name (lower case) in the current row, else null; for use in SQL. |
| value_modified | True when the user modified the column of parameter p_parameter_name (lower case) in the current row; always true for a csv or xlsx file. |
| value_changed | True when the column was modified, is not read only, and p_new_value differs from the existing value p_old_value, null and a value counting as different. |
| value_changed_ | As value_changed, and always true for the action create. |
| new_value | Returns the value to pass to an Oracle API: p_new_value on create or when value_changed is true, else the existing value p_old_value. |
Routines
action_meaning
function action_meaning(p_action in varchar2) return varchar2
Returns the translated display value of an upload action code (C create, U update, D delete), as shown in the Action column; the code itself when it has no translation.
status_meaning
function status_meaning(p_status in varchar2) return varchar2
Returns the translated display value of an upload status code (N new, V valid, I invalid, E error, W warning, S success), as shown in the Status column; the code itself when it has no translation.
action_create
function action_create return varchar2
Returns the action code for create (C), for SQL, which cannot reference package constants.
action_update
function action_update return varchar2
Returns the action code for update (U).
action_delete
function action_delete return varchar2
Returns the action code for delete (D).
status_new
function status_new return varchar2
Returns the status code new (N).
status_valid
function status_valid return varchar2
Returns the status code valid (V).
status_invalid
function status_invalid return varchar2
Returns the status code invalid (I).
status_error
function status_error return varchar2
Returns the status code error (E). An upload procedure sets status_ to it to reject a row.
status_warning
function status_warning return varchar2
Returns the status code warning (W).
status_success
function status_success return varchar2
Returns the status code success (S).
run_id
function run_id return number
Returns the run id of the upload being processed, the key of its rows in xxen_upload_data and of its run in xxen_report_runs.
property
function property(p_property_name in varchar2) return varchar2
Returns a custom document property of the uploaded workbook, for example xxen_run_id, the run id of the download that created it, or xxen_template_id; null when the file does not carry it, such as a csv file.
submit_upload_process
function submit_upload_process(p_report_name in varchar2, p_template_name in varchar2, p_file_id in number, x_request_id out nocopy number) return varchar2
Submits the upload of a workbook stored in fnd_lobs (p_file_id) as a concurrent request for the upload p_report_name with template p_template_name. Returns null on success, else the error message; x_request_id is 0 when the submission fails. Commit to release the request.
function submit_upload_process(p_report_name in varchar2, p_template_name in varchar2, p_file_id in number, x_request_id out nocopy number, x_run_id in out nocopy number, p_process_mode in varchar2 default null) return varchar2
As above, and returns the run id in x_run_id, which keys the uploaded rows in xxen_upload_data. The current responsibility must have access to the upload, else the function returns a message and submits nothing.
attach_source_file
procedure attach_source_file( p_function_name in varchar2, p_function_type in varchar2, p_category_name in varchar2, p_entity_name in varchar2, p_pk1_value in varchar2, p_pk2_value in varchar2 default null, p_pk3_value in varchar2 default null, p_pk4_value in varchar2 default null, p_pk5_value in varchar2 default null )
Attaches the uploaded file to an EBS record as a File attachment, for example to the journal or invoice the upload created. The attachment is added once all rows are processed, so it can be called per row; p_category_name is the internal category name.
check_and_add_attachment
function check_and_add_attachment( p_function_name in varchar2, p_function_type in varchar2, p_category_name in varchar2, p_entity_name in varchar2, p_data_type in varchar2, p_title in varchar2 default null, p_description in varchar2 default null, p_text in varchar2 default null, p_file_id in varchar2 default null, p_pk1_value in varchar2, p_pk2_value in varchar2 default null, p_pk3_value in varchar2 default null, p_pk4_value in varchar2 default null, p_pk5_value in varchar2 default null ) return varchar2
Adds an attachment to an EBS record unless an identical one exists. p_category_name and p_data_type are display names (data types File, Short Text or Web Page); p_text is the text or URL, p_file_id a semicolon-separated list of fnd_lobs file ids. Returns p_text when the attachment exists or was added, Error:<message> when adding failed, null when a required argument is missing. Runs in an autonomous transaction, so the attachment stays when the row is rolled back.
parameter_exists
function parameter_exists(p_parameter_name in varchar2) return boolean
True when the upload procedure parameter p_parameter_name (lower case) is mapped to a column of the uploaded file.
read_only
function read_only(p_parameter_name in varchar2) return boolean
True when the column of the parameter p_parameter_name (lower case) is read only in the upload or its template.
value_modified_
function value_modified_(p_parameter_name in varchar2, p_modified_columns in varchar2 default null) return varchar2
Y when the user modified the column of parameter p_parameter_name (lower case) in the current row, else null; for use in SQL. Always Y for a csv or xlsx file, which carries no record of modified cells.
value_modified
function value_modified(p_parameter_name in varchar2, p_modified_columns in varchar2 default null) return boolean
True when the user modified the column of parameter p_parameter_name (lower case) in the current row; always true for a csv or xlsx file.
value_changed
function value_changed(p_parameter_name in varchar2, p_new_value in varchar2, p_old_value in varchar2, p_modified_columns in varchar2 default null) return boolean
True when the column was modified, is not read only, and p_new_value differs from the existing value p_old_value, null and a value counting as different. For a number column p_old_value is first rounded to the upload's decimal places.
value_changed_
function value_changed_(p_parameter_name in varchar2, p_new_value in varchar2, p_old_value in varchar2, p_action in varchar2, p_modified_columns in varchar2 default null) return boolean
As value_changed, and always true for the action create. Sets the global g_value_changed to the result.
new_value
function new_value(p_parameter_name in varchar2, p_new_value in varchar2, p_old_value in varchar2, p_action in varchar2, p_modified_columns in varchar2 default null) return varchar2
Returns the value to pass to an Oracle API: p_new_value on create or when value_changed is true, else the existing value p_old_value. On update a cleared cell returns fnd_api.g_miss_char, which Oracle update APIs read as set to null. Sets g_value_changed.
function new_value(p_parameter_name in varchar2, p_new_value in number, p_old_value in number, p_action in varchar2, p_modified_columns in varchar2 default null) return number
As new_value for a number; a cleared cell on update returns fnd_api.g_miss_num.
function new_value(p_parameter_name in varchar2, p_new_value in date, p_old_value in date, p_action in varchar2, p_modified_columns in varchar2 default null) return date
As new_value for a date; a cleared cell on update returns fnd_api.g_miss_date.
Generated from Blitz Report 3.3.7 on .