码迷,mamicode.com
首页 > 其他好文 > 详细

【EBS】代码提交请求

时间:2016-06-06 18:27:52      阅读:585      评论:0      收藏:0      [点我收藏+]

标签:

提交请求

用来提交一个请求,它返回一个NUMBER值.具体调用如下

  1. :RESULT := fnd_request.submit_request(application, --AP模快
  2. program, --应用程序
  3. description, --请求说明(可选)
  4. start_time, --RUN 时间(可选)
  5. sub_request, --立刻提交请求
  6. argument1, --参数1
  7. argument2, --参数2
  8. argument3, --参数3
  9. argument4, --参数4
  10. argument5, --参数5.......
  11. argument100);
  • application:Short name of the application associated with the concurrent request to be submitted.
  • program:Short name of the concurrent program (not the executable) for which the request should be submitted.
  • description:Description of the request that is displayed in the Concurrent Requests form (Optional.)
  • start_time:Time at which the request should start running, formatted as HH24:MI or HH24:MI:SS (Optional.)
  • sub_request:Set to TRUE if the request is submitted from another request and should be treated as a sub-request.
  • argument1...100:Arguments for the concurrent request; up to 100 arguments are permitted. If submitted from Oracle Forms, you must specify all 100 arguments.

输出请求编号

必须Commit,才能输出结果!

  1. fnd_message.set_string(‘已提交请求,编号:‘||to_char(v_request_id)||);
  2. fnd_message.show;

等待请求结束

  1. FUNCTION fnd_concurrent.wait_for_request(request_id IN NUMBER DEFAULT NULL, --请求ID
  2. INTERVAL IN NUMBER DEFAULT 60, --检查时间间隔
  3. max_wait IN NUMBER DEFAULT 0, --最大等待时间
  4. phase OUT VARCHAR2,
  5. status OUT VARCHAR2,
  6. dev_phase OUT VARCHAR2, --请求运行阶段
  7. dev_status OUT VARCHAR2, --各个阶段状态
  8. message OUT VARCHAR2 --运行完成后输出信息
  9. ) RETURN BOOLEAN;
例子
  1. po_req_num := fnd_request.submit_request(application => ‘‘,
  2. program => ‘‘,
  3. sub_request => FALSE,
  4. argument1 => NULL);
  5. COMMIT;
  6. v_request_status := fnd_concurrent.wait_for_request(po_req_num,
  7. 3,
  8. 30,
  9. x_phase,
  10. x_status,
  11. x_dev_phase,
  12. x_dev_status,
  13. x_message);
  14. IF v_request_status THEN
  15. IF x_dev_status = ‘NORMAL‘ THEN
  16. po_req_status := ‘S‘;
  17. ELSE
  18. po_req_status := ‘U‘;
  19. END IF;
  20. ELSE
  21. po_req_status := ‘E‘;
  22. END IF;




【EBS】代码提交请求

标签:

原文地址:http://www.cnblogs.com/jforce/p/5564618.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!