Alerts can add tremendous value to your business processes. A business process can execute thousands of times a day, you only need to know if an exception has occurred in the process. The alert framework in SAP NetWeaver can notify you of these alerts. You have many options on how to react to the alerts. When talking to customers about alerts, many limit the discussion to SAP application modules that natively use the alert framework, such as SCEM, and other customers immediately think of technical alerts in CCMS such as response time and CPU utilization. However, alerts can cover the full gamut of your needs: from technical alerts to business alerts. Since the alert framework is available in every SAP NetWeaver Application Server, alerts can be raised from any SAP system. Additionally, API’s exist so you can have non-SAP systems trigger alerts in SAP NetWeaver. Alerts could occur because of a purchasing process in an ERP system, a KPI alert in a BI system, or a BPM alert coming from SAP NetWeaver Exchange Infrastructure. These alerts can be routed to the user and subsequent actions can be taken. Let’s look at a couple of examples of how you might want to take advantage of using alerts. Triggering an alert The first step with alerts is that the alert has to be triggered. The application system must know it is time to raise an alert. This can happen in many ways. Some applications, such as SCEM, automatically raise alerts. But there are many other ways to raise them as well. Examples include: 1. A workflow event from the business object respository can raise an alert. SAP systems have many events that occur natively, these can be used to trigger alerts. In transaction SWE2 use function module SALRT_CREATE_VIA_EVENT to raise the alert. 2. Use the Post Processing Framework (PPF) to raise an alert. I’m not familiar with the PPF, but I think it’s used in CRM. Please reply if you’ve used this to raise an alert. 3. Beginning in NW04, CCMS can raise alerts via the auto-reaction method. 4. BI process chains can send alerts. 5. Information Broadcasting in BI can also be used to trigger alerts. 6. There is a function module, SALRT_CREATE_API, that can be used to trigger alerts. 7. Integration processes in SAP Netweaver Exchange Infrastructure can raise alerts. So, just get creative – there are many, many ways to get the alerts triggered. Triggering alerts is explained in online help as well. If you just want to trigger an alert to see what you can do, RSALERTTEST is a simple program you can use to raise any alert. Defining an alert and what to do with the alert Alerts are defined in transaction code ALRTCATDEF. In this transaction code you define the name of the alert, and what should happen after the alert has occurred. This is where you can get super creative. Here is an example of an alert I created. I just called it ZMYTEST. When defining alerts, you indicate the subsequent actions that could happen based on the alert. This is where your creativity is your limit. The subsequent actions are defined as a URL. So, this could be any thing that you can render as a URL. In my example I’m starting a guided procedure as the result of an alert. Guided procedures are new in NetWeaver 2004s. I will do blogs on guided procedures in the future (here’s a tutorial for guided procedures), but the cool thing is you can enter ANY URL. However, as far as I know the URL cannot be built dynamically, I think it is a static URL. If you’ve used this with dynamic parameters, please reply so we can learn from your experiences. Deciding who should get the alert In the definition of the alert category, you decide who can get the alert. The awesome thing is that you assign roles, or use subscriptions. Users can also subscribe to alerts themselves as well. Example of how this could work Here’s an example of how this could work, putting the pieces together and rendering the alert to the user. 1. Configure the application to trigger the alert. In my example, I will use a business object in an ERP system. If a purchase order is cancelled, I want an alert to be triggered. Since I have a workflow background, this method is easiest for me. In transaction code SWE2, I am use an event from the business object PURCHASE_ORDER, when the purchase order is cancelled, the funtion module SALRT_CREATE_VIA_EVENT raises the alert category PURCHASE_ORDER_CANCELLED that was created in transaction code ALRTCATDEF.Optionally, I could execute other function modules (CHECK_CUSTOMER_PRIORITY) to see if I really wanted to raise this alert. (For those who don’t know much about SWE2, these addtional function modules do not have to be written, there is a graphically tool you can use to create additional conditions to consider before raising the alert.) 2. I create a guided procedure, and add it as a subsequent action for my alert, PURCHASE_ORDER_CANCELLED. 3. I have configured my Universal Worklist to receive alerts for this system. I discussed this in a blog earlier this year: Integrating Alerts into UWL. This just involves adding the system to UWL and registering it with the alert connector. 4. Now I raise the alert (by cancelling a purchase order, or running RSALERTTEST as a test). The alert gets routed to my Universal Worklist. I click on the alert, and I can see the link to the URL defined for the alert category. Because my URL is linked to a guided procedure, my guided procedure starts. Guided procedures can then link to BI reports, CAF services, SAP transactions, KM objects, function modules, and a variety of other processes. The awesome thing is that my URL launches. Maybe you want to use a URL to launch your custom application or function. Please let me know if this topic interests you, and if you are using alerts. We can do follow-on blogs on alerts, guided procedures, and other tools used to resolve alert situations.