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
Similar Messages
-
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. -
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. -
Sending Notification to a User (common box) without attaching an employee..
Dear all,
I expect all of yours help on this doubt.
I have created custom notification using wf_notification.send based on my logic, now I want to send these notification to common inbox in the Oracle. For this purpose i have created a user and attached the responsibility which includes notification inbox. I don’t want to attach an employee to this common user id because more than 5 people will be accessing this account. Because not attaching an employee, notification are not going to this common box, is there any way to solve this problem. When I am sending this notification to a user where employee already attached, it is working fine.
Regards,
Jojo GeorgeDear Jojo,
Can you please provide the details and procedure to create custom notifications. I need to create for oracle self service HR. i need to send the notifications of certain actions like termination, absence etc for particular persons
Thnak you,. -
Message attribute(document) not populating , if iam sending from procedure
hello,
I am sending messages to various managers from a cursor for loop in my
procedure.
my message has an document type atttribute, which is referencing this item_attribute. and this attribute is the body of my message.
Before sending, i am setting the item attribute of type Document called
'MGR_MESSAGE_BODY' by calling wf_engine.setItemAttribute and
avalue=>
'plsql:koc_overtime_web_pkg02.show_mgr_message_TST/'||itemtype || ':' || ItemKey);
but it seems show_mgr_message_TST is not calling.
PROBLEM is that message is sending, but with empty.
BUT if i am sending messages through workflow builder's notification activity, its working.?
below is the testing code:-
BEGIN
for o in outer_cr(l_batch_id , l_period_id)
Loop
l_second_approver := o.second_approver;
--// LOG
insert into delete_it(COL1, col2, col3, col4) values
(l_batch_id, l_period_id, l_second_approver, o.cnt);
wf_engine.SetItemAttrText(
itemtype => Itemtype,
itemkey => Itemkey,
aname => 'SECOND_APPROVER_KOCNO',
avalue => l_second_approver);
-- wf_engine.SetItemAttrText(
itemtype => itemtype,
itemkey => itemkey,
aname => 'MGR_MESSAGE_BODY' ,
avalue => 'plsql:koc_overtime_web_pkg02.show_mgr_message_TST/'||itemtype || ':' || ItemKey);
tst := wf_engine.GetItemAttrText(
itemtype => Itemtype,
itemkey => Itemkey,
aname => 'SECOND_APPROVER_KOCNO');
insert into koc.delete_it(COL1, col2, col3, col4) values
(' loop-after-getattr: batch, period, second appr', l_batch_id, l_period_id, tst);
l_nid := wf_notification.Send(
role=>l_second_approver,
msg_type=>itemtype,
msg_name=>'MGR_APPROVAL_REQUEST' ,
due_date=>null,
callback=>null,
context=>null,
send_comment=>null,
priority=>null);
insert into koc.delete_it (col1, col2) values ('nid=', to_char(l_nid));
End Loop;
END;Hi Jayanthi,
I want to send email to internet address and not to SAP user. Like for example can I send the attachment to my yahoo id??
If I change to
i_reclist-receiver = give sap user id
i_reclist-express = 'X'.
i_reclist-rec_type = 'B'.
this will surely work but it comes to my SAP Office Inbox but I need to send it to any address on the internet. Is it possible?
Please do reply.
Thanks in advance,
Rashmi -
Need to send FYI Notification - Oracle Applications
Hi,
I need to send FYI notification upon completion of one concurrent program of PL/SQL procedure type. Can I use WF_NOTIFICATION.SEND method? Alreay I have one custome FYI message defined in WF_MESSAGE table. I am new to workflow and dont want to touch or create the workflows....Any help?
ThangsDear All,
I am facing problem regarding completion notifications in Oraclr r12, when user click the upon completion generated notifications it can only be viewd once, second time user cannot view the notifications.
I have find that fnd_file_temp table store this information and deleted it.
Plz help me how to view this URL again.
thanks
regards,
Zubyr -
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 -
Issue in notification API for oracle workflow
Hi,
I am facing issue in sending oracle workflow notification. i have created a simple workflow with a process.
I wrote one package which is creating adhoc role and sending the notification through api I(wf_notification.send).
I am able to get the notification as well as email notification but without attribute values. My workflow attributes are getting replaced by null, but message body is appearing.
Please help me, its urgent.
Thanks
RajniI doubt that Oracle 7 DB is not supported. You may consider raising a SR with support.
Regards,
Anuj -
Notification messages set at run time
I would like to be able to send different message body content at the same place in my workflow determined by settings of a couple of attributes at run time.
Is the correct approach to create a function call which has the PLSQL to determine the attribute settings and then calls wf_notification.send with the appropriate message name? If so, how do I then handle the response to this notification (Y or N)?
I am using 2.6 standalone.
Cheers
Mike GHi.. I have to use the Notification API (Send) because I dont want to use item attributes (all the notification info like performer and message body is generated in runtime)
But, just as stated here, the Workflow callback function was giving problems. How can I implement my own callback function? the examples in WF guide aren't enough clear for me! Can abyone help me with this? -
Manual notifications on SR update
Hi,
I have a requirement to send Manual notifications to customer contacts whenever SR is updated from Customer support SR form.
On other events like SR creation closure etc.. notifications should fire automatically.
So it is like sending automatic notifications on few events on SR and manual notifications on other few events.
For setting up automatic notifications in SR, i am defining rules in Notifications rules ( Customer Support --> Setups --> SR --> Notification rules).
Need pointers in setting up manual notifications for SR ( Service representative should be able to send manually a notification to customer contacts that SR has been updated). Does this need customization in workflow?
PLease note that we are on Oracle Apps 11.5.10.2 and implementing Services modules like Teleservices, iSupport, etc..
Any helpful hints are appreciated.
Regards,
MohammedMohammed
You can try two options:
1. You personalize the SR Screen adding an option to Tools (using special menus)-->Send Notifications to Customer Contacts. The action on this screen will use wf_notification.send to pump out the notification to your customer contact WF roles.
2. You can use SR Update business event to automatically send the notification to the SR customer contact under special conditions you want that notification to go to. The way this option differs from above one is that you have code the condition in your code where as you are doing it 'as-and-when-you-want' in the first option.
I am not aware of any standard functionality.
Thanks
Nagamohan -
Application Error has occurred in your process Leave of Absence performed
Hello,
We have a leave process in SSHR Module.When we create a leave and send it for an approval then it is approved without an error. But when we update the leave and send it again for an approval then We are getting below error.
Application Error has occurred in your process Leave of Absence performed
The changes were not applied because ORA-01403: no data found ORA-01403: no data found
We have removed all user hooks related to leave.Still error is coming. We are using 12.1.3 version.
Thanks in Advance,
Regards,
monikaHi Monika,
One more thing i want to tell that when i am checking the transaction from workflow Admin then its showing an error in below activity.
"Notify HR About Commit System Error"
Below error stack has been found in workflow ADMIN
Workflow Errors:
Failed Activity Notify HR About Commit System Error
Activity Type Notice
Error Name WFNTF_ROLE
Error Message 3205: '[email protected]' is not a valid role or user name.
Error Stack Wf_Notification.Send([email protected], HRSSA, HR_EMBED_DEPT_SYSAPPLERR_MSG, WF_ENGINE.CB) Wf_Engine_Util.Notification_Send(HRSSA, 8155, 1296851, HRSSA:HR_EMBED_DEPT_SYSAPPLERR_MSG) Wf_Engine_Util.Notification(HRSSA, 8155, 1296851, RUN)
please see this
The Exception ' The changes were not applied because A person type with a system person type EMP must be specified' is Raised While Appoving Changes to Employee Personal Details. [ID 1545950.1]
Application Error Notification Is Recieved By Requestor After LOA Approval [ID 855141.1]
;) AppsmAsti :)
sharing is caring -
Sales Order header still booked when lines are already closed
Hello all,
Well, im having problems to close a couple of Sales Orders...the lines are already closed but the headers reminds as 'Booked'....I checked the Workflow and one of the SO shows me this error message:
Error Message ORA-00376: file 354 cannot be read at this time ORA-01110: data file 354: '+LIVE_DG/liveclrvenus2/datafile/undotbs1a.801.702318343' ORA-00376: file 354 cannot be read at this time ORA-01110: data file 354: '+LIVE_DG/liveclrvenus2/datafile/undotbs1a.801.702318343'
Error Stack Wf_Event.Dispatch(oracle.apps.wf.notification.send) Wf_Notification.SendSingle(SYSADMIN, OMERROR, OMERROR_MSG, 26-JAN-11, WF_ENGINE.CB) Wf_Notification.Send(SYSADMIN, OMERROR, OMERROR_MSG, 26-JAN-11, WF_ENGINE.CB) Wf_Engine_Util.Notification_Send(OMERROR, WF2835788, 143218, OMERROR:OMERROR_MSG) Wf_Standard.Notify(OMERROR, WF2835788, 143218, RUN) Wf_Engine_Util.Function_Call(WF_STANDARD.NOTIFY, OMERROR, WF2835788, 143218, RUN)
Anyone knows how to fix this......
Regards
Edited by: 843193 on Mar 11, 2011 2:59 PMSee docs "Close Sales Order Headers With No Associated Open Lines, Order Header Workflows Or Order Line Workflows [ID 397565.1]" and "Order Management Suite - Some Datafix Patches and Scripts [ID 398822.1]". They might help. I currently have an SR in on the same situation, although I do not get the same error message you get.
Hope this helps,
Dana-B
Edited by: user9971618 on May 2, 2011 12:21 PM
Edited by: Dana-B on May 2, 2011 12:22 PM -
ORA-01422: Exact fetch returns more than requested no of rows
Hi experts.
There is on requeter and one Supervisor to approve the request. But if see the errors in Workflow Administration Web Applications,see the above error message. How come this error message, if i have one approver in the notication process.That is: the wf_notification sending multiple notifications from single activity in the loop.
Any idea?????
ThxIt is a problemin workflow Notification.
Refer to:
OM QUOTE APPROVAL: WF_NOTIFICATION.SEND ERRORS WITH ORA-01422 [ID 1078855.1]
ORA-01422 error happens in wf_notification.send when multiple notifications are sent from single activity in loop. The query which returns more than one row is in WF_NOTIFICATION.send
Mehdi -
Message Attribute value not getting populated
Hi,
We are using the WF_NOTIFICATION.send() API to send a notification. We have some attributes in the subject and body. We are setting the values to these attributes using WF_NOTIFICATION.SetAttrText() API. Notification is sent successfully, but the values for the attributes in the subject line is not getting set (returns blank), but if we use the same attribute in the message body, the values are properly set (returns the value). The values are properly getting updated in the table wf_notification_attributes.
e.g. We have an attribute NAME, in the subject and body we use &NAME, the subject returns null, where as body returns attribute value.
Please let us know what is the issue?
Is there any way of sending notification (using some other standard API), but subject attribute should get updated with actual value?
Thanks in advance.Hi,
See OWF forum message:Re: wfnotificationapi.getsubject() 's return value
There is a bug related in Metalink: Doc ID = 229566.1
fact: Oracle Workflow Cartridge
symptom: Regional settings other than English
symptom: Statement WFNotificationAPI.getSubject(context, new BigDecimal(125)
) always returns null.
symptom: The method WFNotificationAPI.getSubject returns the subject of the
message if the regional setting is English (United States)
cause: Bug 2379277 Oracle Workflow Java Notification API Multilingual
Problem
The language is not recognized by WF as an installed language.
fix:
1. Follow the instructions for installing an additional language in The Oracle
Workflow Server Installation Notes
2. Rerun the test by creating a new message.
IMPORTANT! The old message will not have a row in the table until they load one
for that language.
Reference:
The Oracle Workflow Server Installation Notes -
ORA 000931 - Missing identifier
HI All,
I am running workflow 2.6 on windows 2000 and have found an issue that I cannot resolve.
when i respond to a notification ocurrs the following error:
Error Message:
0RA - 00931: missing identifier
Erro Stack:
WF_XML.EnqueueMessage([WF_SCHEMA].WF_SMTP_0_1_QUEUE,50,2343)
WF_XML.EnqueueNotification(2343)
WF_Notification.SendSingle(ETC,CF_FACT,MSG_APPROVE_FACT,WF_ENGINE.CB)
WF_Notification.Send(ETC,CF_FACT,MSG_APPROVE_FACT,WF_ENGINE.CB)
Wf_Engine_Util.Notification_Send(CF_FACT,153,7845,CF_FACT:MSG_APPROVE_FACT)
Wf_Engine_Util.Notification(CF_FACT,153,7845,RUN)
Thank you.Hi Jorge
You should work with Support on these kind of issues, you can log an iTAR via Metalink or there is also a Support Technical Forum. You should let them know what langgauges you have installed for workflow, and the results of the following SQL:
select name, text, language from wf_resources where name='WF_SCHEMA'.
Hope that helps.
Cheers
Mark
HI All,
I am running workflow 2.6 on windows 2000 and have found an issue that I cannot resolve.
when i respond to a notification ocurrs the following error:
Error Message:
0RA - 00931: missing identifier
Erro Stack:
WF_XML.EnqueueMessage([WF_SCHEMA].WF_SMTP_0_1_QUEUE,50,2343)
WF_XML.EnqueueNotification(2343)
WF_Notification.SendSingle(ETC,CF_FACT,MSG_APPROVE_FACT,WF_ENGINE.CB)
WF_Notification.Send(ETC,CF_FACT,MSG_APPROVE_FACT,WF_ENGINE.CB)
Wf_Engine_Util.Notification_Send(CF_FACT,153,7845,CF_FACT:MSG_APPROVE_FACT)
Wf_Engine_Util.Notification(CF_FACT,153,7845,RUN)
Thank you.
Maybe you are looking for
-
To be honest I don't need a lot of people commenting on this. I need Apple to comment because too many people have complained and they seem not to give a stuff. So will I be buying an Apple iPad 2 or 3? NOOOOOO! I suppose the only way is to protes
-
My daughter's iPhone 3gs has just been replaced by Apple. When she tried to restore her backup files she was told to upgrade to itunes 10, but she can't because her Macbook is too old to run it. What do we need to do to get all her stuff onto the new
-
How do I add a photo to an animated background?
How do I add a photo to an animated background?
-
Hi My Phone's 5220 express music in my phone it shows that my firmware version is 06.51 but the nokia software updater shows that the latest available version for my product code is 05.63 !!!! anyone got any idea ??? Solved! Go to Solution.
-
When I go to open a link within a tab, it overrides what is there and opens. I would lik the option of opening a link from within a tab or the menu bar, into a new tab. I cant find that option, the only one being opening a new windows in a new tab Ca