WF_NOTIFICATION
I am using WF_NOTIFICATION(ATTRS,<attr1>,<attr2>..) in my message body. Now i need to dispay an URL using this WF_NOTIFICATION. Is it possible?
Hi Pradeep,
Were you able to solve the puzzle. We also have same requirement and struggling for leads.
-Satya
Similar Messages
-
Join condition between PO_REQUISITION_HEADERS_ALL and WF_NOTIFICATIONS
Hi,
Could anyone tell me what is the join condition between PO_REQUISITION_HEADERS_ALL and WF_NOTIFICATIONS?
I joined these two tables by WF_NOTIFICATIONS.ITEM_KEY = PO_REQUISITION_HEADERS_ALL .WF_ITEM_KEY.But I cannot found some approved requisitions item key in WF_NOTIFICATIONS table.
Please help.
I paste my query below:
SELECT PRH.ORG_ID ORG_ID,
WF.ITEM_KEY,
WF.FROM_ROLE,
PRH.WF_ITEM_KEY,
WF.RECIPIENT_ROLE APPROVERS_NAME,
TRUNC(NVL(PRH.APPROVED_DATE, '')) DATE_APPROVED,
WF.SUBJECT SUBJECT,
PRH.DESCRIPTION REQ_DESC,
PRH.SEGMENT1,
(SUM(NVL(PRL.AMOUNT, 0)) +
SUM(NVL(PRL.UNIT_PRICE, 0) * NVL(PRL.QUANTITY, 0))) REQ_AMT,
GL.SEGMENT1 || '.' || GL.SEGMENT2 || '.' || GL.SEGMENT3 || '.' ||
GL.SEGMENT4 || '.' || GL.SEGMENT5 || '.' || GL.SEGMENT6 || '.' ||
GL.SEGMENT7 || '.' || GL.SEGMENT8 CHARGE_ACCT
FROM APPS.WF_NOTIFICATIONS WF,
APPS.PO_REQUISITION_HEADERS_ALL PRH,
APPS.PO_REQUISITION_LINES_ALL PRL,
APPS.PO_REQ_DISTRIBUTIONS_ALL PRD,
APPS.GL_CODE_COMBINATIONS GL
WHERE WF.FROM_ROLE IN ('GHAWKINS', 'GHALVERSON', 'NCERNOTTA', 'DCOLLOPY', 'RHAY')
AND BEGIN_DATE > SYSDATE - 60
AND WF.MESSAGE_TYPE = 'REQAPPRV'
AND WF.ITEM_KEY = PRH.WF_ITEM_KEY --added
AND PRH.AUTHORIZATION_STATUS = 'APPROVED'
AND PRL.REQUISITION_HEADER_ID = PRH.REQUISITION_HEADER_ID
AND PRD.REQUISITION_LINE_ID = PRL.REQUISITION_LINE_ID
AND PRD.CODE_COMBINATION_ID = GL.CODE_COMBINATION_ID
GROUP BY PRH.ORG_ID,
WF.ITEM_KEY,
WF.FROM_ROLE,
PRH.WF_ITEM_KEY,
WF.BEGIN_DATE,
WF.SUBJECT,
WF.RECIPIENT_ROLE,
PRH.APPROVED_DATE,
PRH.DESCRIPTION,
PRH.SEGMENT1,
PRL.REQUISITION_HEADER_ID,
GL.SEGMENT1 || '.' || GL.SEGMENT2 || '.' || GL.SEGMENT3 || '.' ||
GL.SEGMENT4 || '.' || GL.SEGMENT5 || '.' || GL.SEGMENT6 || '.' ||
GL.SEGMENT7 || '.' || GL.SEGMENT8Pl see if these MOS Docs can help -
603232.1 - How to Diagnose Purchasing Document Approval Routing
579522.1 - Forward Document Form FAQ
431767.1 - How To View Requisition From The Email Notifications For Which Workflow Data Is Purged
HTH
Srini -
Hi I am getting the following error in wf_notifications for a particular requisition
Hi ,
One of the users reported that a workflow notification was suddenly sent out after two years for a requistion that was closed two years back.
On checking the wf_notifications table , the error that was noticed read as :-
Approval workflow database error occurs while approving Purchase Requisition 9905298
Context: POERROR:3103003-215197:154263 in the wf_notification table
A response in this regard will be highly appreciated
Thanks
SouravCheck weather Your able to Ping Data warehouse, might be your ETL is not able to ping DW.
-
Hi,
we are getting error message on the requisition notification form. when the user is logging into apps and opening the requisition approval notification for particular requisition the error messgae is displayed at the top of the notification acreen. though the error message is not preventing the user from approving the requisition. he is successfully able to approve the requistion. but the user doesn't want to seee this error message.
please suggest on how to hide this error message.
error message ------- ORA-06502: PL/SQL: numeric or value error ORA-06512: at "APPS.WF_NOTIFICATION", line 5361 ORA-06512; at line 5
Thanks,
SamDHi,
I wrote about this in 2008 on my blog when I hit the problem in 11.5.9 - http://www.workflowfaq.com/workflow-notification-fails-when-action-history-becomes-too-long
Have a look at the bug, patches and workaround on there and see if that helps solve your problem.
HTH,
Matt
WorkflowFAQ.com - the ONLY independent resource for Oracle Workflow development
Alpha review chapters from my book "Developing With Oracle Workflow" are available via my website http://www.workflowfaq.com
Have you read the blog at http://www.workflowfaq.com/blog ?
WorkflowFAQ support forum: http://forum.workflowfaq.com -
Message body is empty, when calling wf_notification.send ,
hi,
i am sending a messages to 5 peoples, using wf_notification.send api.
but the when i check the emails, mesage body is empty.
prior to calling wf_notification.send Api,
my message body has been generated by the message attribute of type document(plsqlclob), iam using wf_engine.setItemAttribute and the argument avalue is like this
avalue=> 'plsql:koc_overtime_web_pkg02.show_mgr_message_TST/'||itemtype || ':' || ItemKey) for setting this message attribute(this will generate html)
Shall i need to use any callback function in my send api.
regards.
zameer.If you are using WF_ENGINE.SetItemAttrText API, I see that you have a workflow item that is launched. In such a case you could just have a notification activity within the same process that will send the notification and the e-mail appropriately.
Why do you use WF_NOTIFICATION.Send using an attribute value that is set from a Workflow item.
Typically WF_NOTIFICATION.Send function is used to send a notification outside of a workflow process. Typically you would use a workflow message definition and corresponding message attribute definition and use the following code to send the notification.
declare
l_nid number;
l_user varchar2(320) := '&1';
l_begin_date date;
begin
l_nid := wf_notification.send(l_user, 'CS_MSGS', 'FYI_MESSAGE');
wf_notification.setattrtext(l_nid, 'SENDER', 'Oracle Workflow Testing Mailer');
wf_notification.setattrtext(l_nid, 'MESSAGE_TEXT', ' Message sent at '||to_char(sysdate,'DD-MON-RRRR HH24:MI:SS')||' DB server time');
wf_notification.denormalize_notification(l_nid);
commit;
end;
/As you can observe, I do not depend on any workflow item for any attribute information. Please note that in case if there is a requirement to depend on a workflow item, it is required that you need to pass a Callback function and Context to WF_NOTIFICATION.Send function in order for the workflow item attribute information to be copied over to notification attributes. -
Hi,
I am having a wft program, which checks a function activity and depending on the value returned sends difference notifications.
The package body completed successfully from backend and while running the workflow program it sends a notification also. But while opening the notification it gives the following error,
ORA-20006: ORA-01722: invalid number ORA-06512: at "APPS.WF_NOTIFICATION", line 5328 ORA-06512: at line 5
I have 3 procedures in my package body and all the 3 procedures have exceptions defined as follows, if they are using any workflow activities.
==========================================================
EXCEPTION
WHEN OTHERS THEN
WF_CORE.context (
'WFCustCheck',
'MisCustDataFromTableDoc',
document_id,
display_type,
document,
document_type,
SQLERRM
RAISE_APPLICATION_ERROR (-20006, SQLERRM);
==========================================================
But I am not able to figure out what is causing this error. What does this "line 5328 ORA-06512: at line 5" in the error message indicate?. My package body has only 600 lines. And why is the error message not displaying the procedure name? though I have defined the procedure name in the exception.
What is the best way to get the procedure name in the error message? So that it becomes easier for identifying which procedure is causing the erro?
Please let me know.
ThanksHi,
Instead of the RAISE_APPLICATION_ERROR command, just replace that with RAISE;
The error is coming out of the package that is sending the notification (WF_NOTIFICATION), which is invoked when you open the notification. I'm guessing that line 5 is the line in your code though.
Are you using documents to send the notification, or are they purely defined in the .wft file?
Matt
Alpha review chapters from my book "Developing With Oracle Workflow" are available on my website:
http://www.workflowfaq.com
http://forum.workflowfaq.com
NEW! - WorkflowFAQ Blog at http://thoughts.workflowfaq.com -
Wf_notification.respond issue
We are making our own page to display PO details and take action like "Approve", "Reject", "Approve and Reject" and "Forward". The requirement is similar to EBS Notifications page but due to some constraints we want the approver to action PO from internally developed screen instead of EBS Notifications.
We are trying to approve and forward po approval by calling wf_notification.respond and passing result as approve_and_forward. But nothing is happening. But when we are passing approve and reject as result and then call wf_notification.respond it works.
WFsupport team provided :
Wf_Notification.Forward(nid in number,
new_role in varchar2,
forward_comment in varchar2,
user in varchar2,
cnt in number,
action_source in varchar2)
Wf_Notification.Transfer(.... );
wf_notification.Respond(.... );
Core Workflow team doesn't know how the seeded ApI's are implemented by different Functional Teams and because the Workflow Development team is not aware of the Business Logic from behind need help from the PO Development team.
thanks
mihai
WF support teamYou'll need to call the wf_notification.setAttrText (or Number or Date) function first to give the RESPOND attribute a value before you can call the wf_notification.respond procedure.
Cheers,
Rob -
I am new to the workflow. I want to use wf_notification.send. For the spec of this api, there is a msg_type parameter. What value I need to pass for this parameter? Please give me an example. Morever, I plan to use this wf_notification.send for the post-notification function. What kind of mode it will be when the post-notification function is called?
Hello, for the WF_NOTIFICATION, you can refer to Oracle Workflow API Reference Release 2.6.3 Chaper 4-12.
You can download this documentation from http://www.oracle.com
Cheers!
Citrine -
WF_NOTIFICATION.send
Hi All,
I am trying to use WF_NOTIFICATION.send for the 1st time. The requirement is that I have following piece of code in my pl/sql package which is called form the function activity of the workflow. The following code is inside the loop of the supplier list. So I want to send the notification to each of the supplier picked up in the loop.
If it not giving me any error in pl/sql or workflow, with debug I have checked it it getting correct value for l_tp_contact but still when I log-in as the supplier (user) in the worklist there is no message to that supplier.
=====
l_notification_id := WF_NOTIFICATION.send (role => l_tp_contact,
context => p_itemtype||':'||p_itemkey||':'||to_char(p_actid),
msg_type => 'PONAWARD',
msg_name => l_message_name);
===
Can some one please help.
Thanks!I am guessing, because I haven't done this with PL/SQL code before, but when you say you are looping through suppliers, is this a loop in your PL/SQL or a loop in the workflow? I have had problems before with notifications not being generated from inside a workflow loop because I had my On Revisit set incorrectly (Reset instead of Loop) on the notification step.
Also, is the notification a response required notification or an FYI notification? Where the notification is an FYI, the status of the notification can be updated when generating the email, so querying open notifications on the supplier's worklist could be missing it where the email has been generated.
A good check for both of these is to see if you can find anything in the WF_NOTIFICATIONS table for these notifications?
theFurryOne -
Wf_notification mail_status failed
Hi All,
I configured workflow mailer services in R12 instance and i checked the workflow services each and evey services are up and running.. while sending the TEST MAILER am not getting any mails.
Checking with WF_NOTIFICATIONS table with particular user which i send it showing that the status column is "OPEN" and mail_status column is "FAILED".
And also checked the worklist notification in OAM it showing like "Subsequently the notification preference for the following users has been set to DISABLED" wot it mean.
kindly give any suggestion to move further.
Thanks & Regards
DineshHi,
Can you find any errors in the workflow log file?
Please check the docs referenced in these docs.
R12 Notification Mailer
Re: R12 Notification Mailer
Workflow notification Mailer Not sending notifitions in R12
Re: Workflow notification Mailer Not sending notifitions in R12
Thanks,
Hussein -
Hello all,
I'm using the below code to send the notication using plsql package. It works fine and sends notification if i don't use '#FROM_ROLE' and 'SENDER' attributetext in the code. If i use them, i get the error message. Please advice
L_MESSAGE_TYPE := 'WFMAIL';
L_MESSAGE_NAME := 'OPEN_MAIL_FYI';
L_NID := WF_NOTIFICATION.SEND(UPPER(P_USER_NAME),
L_MESSAGE_TYPE,
L_MESSAGE_NAME);
WF_NOTIFICATION.SETATTRTEXT(L_NID, 'SUBJECT', P_SUBJECT);
WF_NOTIFICATION.SETATTRTEXT(L_NID, 'BODY', P_TEXT_BODY);
WF_NOTIFICATION.SETATTRTEXT(L_NID, '#FROM_ROLE', 'USERNAME1');
WF_NOTIFICATION.SETATTRTEXT(L_NID, 'SENDER', 'USERNAME1');
WF_NOTIFICATION.DENORMALIZE_NOTIFICATION(L_NID);
Thanks
KKHi KK,
What error you are getting when you set the attributes '#FROM_ROLE' and 'SENDER'?
when you set '#FROM_ROLE' then Wf_Notification.Denormalize_Notification(nid) API will be called. If the attribute is 'sender' then event 'oracle.apps.wf.notification.setattrtext wll be rasied. -
Logging wf_notifications
Please, what´s the best approach for logging the wf_notifications table in my own database table. I mean, every time a notification is send or update I could copy it to one another database.
I am not sure a Business Event would be a good idea or if a should use the good and old Trigger.
I need it because this way I could execute the WF_PURGE without loosing my audit trail.
TIA,
ItamarExcuse my question Raja,
There are some specifics methods to periodically back up the schema/tables to the workflow database that you can to recommendable?
Thank very much
-Manuel Pulido -
Wf_notification.getNtfResponse in post notification function
Didn't have too many responses for my previous post, so have to ask again -
can I use wf_notification.getNtfResponse function in the post notification function?
Thank you.
Anatoliy SmirnovHello Matt,
Thank you for the response. Was not sure if this was an answer or a question, so here is a signature for the function in question from wf_notification package shipped by someone named 'dmani' I guess. Using it in postNotification function always returns NULL. Just wanted to hear from Oracle or someone if this is another feature or I am missing something or this can not be used there.
Regards,
Anatoliy
/* $Header: wfntfb.pls 115.230.115102.2 2005/05/16 06:04:07 dmani ship $ */
-- getNtfResponse
-- Fetches result(response) CODE and response display prompt to the notification
-- IN
-- p_nid - Notification ID
-- OUT
-- p_result_code Result code of the notification
-- p_result_display Display value of the result code
procedure getNtfResponse (p_nid in number,
p_result_code out nocopy varchar2,
p_result_display out nocopy varchar2); -
How to delete some of records from wf_notifications table any API Name?
Hi All,
I want to delete some of records from wf_notifications table , can any one tell API' name and Back end delete process.
Thanks,
Ramu
Edited by: Ramu on Mar 20, 2013 5:42 AMHi ,
I hv done below script, now it's working fine.
DECLARE
CURSOR csr_transaction_id IS
SELECT hat.transaction_id,
hat.item_type,
hat.item_key,
ppx.employee_number,
hat.section_display_name
FROM hr_api_transactions hat, per_people_x ppx
WHERE hat.process_name = 'HR_PERSONAL_INFO_JSP_PRC'
AND hat.selected_person_id = ppx.person_id
AND ppx.employee_number IN
('100024773',
'100024820',
'100024859',
'100024879',
'100024902',
'100024937',
'100025137',
'100026470',
'610014755',
'610017039')
order by ppx.employee_number;
BEGIN
dbms_output.put_line('***Deleted all Transactions and Notifications of below Employee Personals Tranactions ***');
FOR my_cur_v IN csr_transaction_id
LOOP
/*Delete all Transaction_id's in hr_api_transactions,hr_api_transaction_steps,hr_api_transaction_values and hr_api_transaction_steps_bk tables */
hr_transaction_swi.delete_transaction
p_transaction_id =>my_cur_v.transaction_id,
p_validate => hr_api.g_false_num
wf_engine.abortprocess (
itemtype => my_cur_v.item_type,
itemkey => my_cur_v.item_key
/* Deleted all Notification_id's and item_key's in wf_item_activity_statuses,wf_items,wf_item_attribute_values,wf_notifications Table */
wf_purge.items (
itemtype => my_cur_v.item_type,
itemkey => my_cur_v.item_key
dbms_output.put_line('Emp No --'||my_cur_v.employee_number||'Transaction_id :'||my_cur_v.transaction_id||'Emp Personal Info :'||my_cur_v.section_display_name||
'Item Type :'||my_cur_v.item_type|| 'Item Key :'||my_cur_v.item_key);
END LOOP;
commit;
EXCEPTION
WHEN OTHERS THEN
dbms_output.put_line('hr_transaction_swi.delete_transaction api goest to exception block' ||sqlcode|| ' '||sqlerrm);
END;
/thanks,
Ramu -
How to capture insert into wf_notifications table
we are building a custom app, which needs to know as soon as a row in insterted into the wf_notifications table, and we want to avod creating a on insert trigger on this table.
Is there a way to figure out that a row is being inserted into this table without having to write a trigger.
Thanks
TapashOracle Workflow raises a business event oracle.apps.wf.notification.send as soon a notification record is created in WF_NOTIFICATIONS table. This business event has parameters such as NOTIFICATION_ID, RECIPIENT_ROLE etc. If you have access to the notification id you may access all other information from WF_NOTIFICATIONS table.
You may create a subscription to this business event with On Error -> Skip property so that in case of an error, your subscription does not impact the normal processing of seeded subscriptions. You may have a PLSQL rule function in the subscription to process the logic required when the notification is created.
Please refer to Oracle Workflow Developer Guide for more information on using Business Event System.
Hope this helps.
Vijay
Maybe you are looking for
-
How to retrieve accidentally deleted mailboxes from Time Machine?
I recently did a reinstall and, winding up with two Mail programs, trashed the one I was "sure" was the new, bogus one. Unfortunately, it was my original Mail program, including the mailboxes with letters from Swedish relatives, important addresses,
-
Error while invoking custom API using Database Adapter
Hi, I've a requirement where in I need to fetch the data returned by a recordtype of a custom API. I've implemented this by invoking the custom API using Database Adapter. I'm facing a problem while performing this. The custom API holds the signature
-
GUI_Download Formating Issue
Hi All, I am using GUI_DOWNLOAD function module to downlaod data to excel sheet and below is my code CONCATENATE P_file '\' 'Sheet_' TX_pernr '_' sy-datum '_' sy-uzeit '.XLS' into lv_File . CALL FUNCTION 'GUI_DOWNLOAD' EXPORTING FILEN
-
Hi! I', m working with TestStand Version 4.2.1. I have a main sequence, which calkls different subsequences. All these steps are properly reported. One of subsequences runs as "new thread". How can I include its results in common test report of the m
-
Track changes for Standard Heirarchy Cost Center details( Tcode: OKEON)
Hi all, I have a requirement to track the changes for <b>Standard Heirarchy Cost Center</b> data and whenever it change i need to initimate with email to certain group of people in organization. Transaction code : OKEON . Whenever standard heirarchy