« September 2008 | Main | November 2008 »

October 2008 Archives

October 2, 2008

Responsibilities Revisited

The ability to respond: Responsibility

It seems futile to write a blog post about responsibilities in Siebel CRM. Everyone knows that they are used to grant access to views. But if you look closer, there is more than that, especially in newer versions of Siebel.

But let me begin with a different perspective. Let’s consider an ideal project, where business analysts follow the golden rule to document the existing processes and start on a high level with mapping the process steps to Siebel views. They would put that information down in a spreadsheet. Then they would extend the spreadsheet with information about the details for every step such as which fields should be filled with what values.

The analysts would also analyze the end user community and identify groups of users who have to execute similar processes.

Finally they would identify gaps in the standard application and design solutions for these gaps. For example a missing field would have to be created by the developer.

Besides the fact that this ideal analyst behavior is rarely found, what does business process analysis or business processes in general have to do with responsibilities?

Consider the graphic below as an attempt to depict the facts stated above. When you start viewing a business process as a set of steps which are carried out in a Siebel view then you need to give all users who have to execute the business process access to these views. So the group maps to the Siebel entity we know as responsibility.

A Siebel Responsibility allows an employee to execute one or more business processes in the Siebel application by granting access to the necessary views. If you conduct a decent business process analysis and documentation, you end up with all the information you need to create both the administrative data (i.e. responsibility and their associations with views and users) and the end user guidance either with iHelp or Task UI.

But there is more to business processes than just navigating from one view to the other and manipulating data. As we discussed in “Close to the Standard”, much of the functionality and automation behind the UI is implemented using business services and workflows, so they are a part of the business process.

And indeed, responsibilities also allow an administrator to grant access to business services and workflows (since version 8.0). The detail views in the Administration – Application > Responsibilities view clearly indicate this (Note that Business Process is used synonymously for Workflow Process).


What else?

Responsibilities also allow an administrator to override the sequence of screen and view tabs by creating individual tab layouts for each combination of responsibility and application. The primary responsibility of an end user will be the driver for the sequence of screen and view tabs that an end user sees after logging in. Tab layout can also be overriden by the end user in the User Preferences > Tab Layout view.

In Siebel 7.5 a simple list applet appeared on the home page view which was labeled "Tasks" offering links to views (as the starting point of a business process such as "Create a service request"). The content of this applet is also driven by the primary responsibility of an end user. Because of the naming conflict with the UI Tasks in Siebel 8.0 the applet and view tab were renamed to "Links".

Responsibilities also provide access to UI Tasks and iHelp items which are the two main tools to guide end users through a business process. So we are back where we started our journey: Responsibilities have a direct relationship to business processes and the application functionality that lies within them.

Let’s summarize the objects which responsibilities can provide access to:

  • Views, of course
  • Tab Layout
  • Links (to views)
  • Workflows
  • Business Services and Methods
  • iHelp Items
  • Tasks (Siebel 8.0 Task UI)
have fun

October 6, 2008

Event Handling in Siebel CRM

a great expedition...

The following is a subject that has been on my mind ever since I started working with Siebel Scripting, a technique to extend (yes - scripting in Siebel is treated as an "extension language") the functionality of Siebel CRM.

Of course many Siebel consultants are familiar with (or have at least several years of exposure to) Siebel Scripting. Sometimes they take it too far and the project is in danger of becoming a house of pain.

But let's not delve into details and the horror of bad code, what I really want to show you today is the Siebel event handling model. This is something that every script writer in Siebel is exposed to because the only place where you can write your code are the provided event handlers for scripting, such as PreInvokeMethod on a business service.

Hopefully, you heard about Runtime Events, another technique to track events in Siebel in a far more elegant manner than script (sorry about that - I know, I frequently step on your programmers toes).

In my classes, I usually do a flipchart drawing on the event model and the so called event flow (which event handler comes first, etc.). It usually looks like this.

click to enlarge
I am quite happy with this chart as it points out that the first opportunity to track the event (and execute custom code) is the browser script, then comes the server side with runtime events first(!), then server scripts, etc.

But the above flipchart drawing does not tell the whole truth, as there is another way to execute custom code when a method is invoked. Namely named methods (pun intended), user properties you can set on the applet or business component level to invoke other methods or business services.

click to enlarge
So it was time for a little experimental setup, which involved creating a small helper business service which allows us to write messages to a trace file. Then I added script code to the applet and business component layer, added named methods and administered runtime events, all of which had the same target: the tracing business service.

Below is a code snippet of the tracing helper service, so you get the basic idea. There is some more code than just TheApplication().Trace() because of the fact that action sets in runtime events encode their context in the property set, so you have to unwrap it (which is nice stuff for yet another post, I think).

click to enlarge
Now we can place a button control on an applet and use it to invoke our method. Once we have compiled everything and click the button, a trace file is written which contains one line per call of our helper business service thus giving us a clear picture of the event handler execution flow inside Siebel.
click to enlarge
Now we can put that information into a nice chart, hopefully useful for all of you who have to extend Siebel functionality with either Scripting, Runtime Events or Named Methods.
click to enjoy ;-)
It wouldn't be Siebel CRM if this would be a complete picture. Of course there are...yes...Signals. This special way to invoke business services as a response to a method invocation has been developed by the team that created the Siebel Order Management module in version 7.8. Signals are only supported by business components that use a special class.

have fun

October 10, 2008

Audit Trail Storage

About large objects with character

A while ago during a Siebel CRM upgrade project, a consultant approached me and asked how and why Oracle has changed the data model of Audit Trail from version 7 to version 8.

After a brief discussion we found out that he referred to a new column in the S_AUDIT_ITEM table. The column is named AUDIT_LOG and has the data type of CLOB (Character Large OBject - newly supported in Siebel 8.0 and above), which enables it to carry a whopping 2 gigabytes of data for each record.

A little bit of investigation reveals that this column stores a string that documents the changes made to the audited record during an update or insert operation. The following screenshot gives you a general idea how this string looks like.

click to enlarge
In earlier versions of Siebel CRM, the S_AUDIT_ITEM table stored one record for each field that was audited, so the table grew very large. Creating a single string with all fields for each update reduces the size of the table significantly.

What was a little unfortunate in the specific project is that they accessed the S_AUDIT_ITEM table with Informatica to incorporate the Audit Trail data into their data warehouse. After the Siebel CRM upgrade, the ETL did no longer work because of the new column.

Furthermore, because of the data type of CLOB and the cryptic nature of the string it was impossible to retrieve Audit Trail data with simple SQL.

I proposed a solution which encouraged accessing the Siebel business component layer using EAI techniques such as Siebel ASI (Application Services Interfaces) and web services. This would eliminate the need to access the physical table directly.

The business component used to display the Audit Trail data is based on a specialized class CSSBCVAuditTrail which makes it a virtual business component. But you can still use it in an integration object and create a read-only ASI. Please find more information about Siebel EAI and ASIs in the Siebel Bookshelf and the Integrating Siebel Applications course.

As the more inquisitive among you might have already found out, the data string in the AUDIT_LOG column looks quite familiar to the one that stores the data modifications for Siebel Remote in the S_DOCK_TXN_LOG table (see screenshot below). But this is a different story...

click to enlarge

October 14, 2008

Runtime Events and Custom Business Services

This is for all of you who work with Runtime Events and Action Sets in Siebel CRM.

Action Sets allow you to define one or more actions to be executed when the associated event occurs. There are three action types:

  • Attribute Set: Set a profile attribute
  • InvokeMethod: Invoke a method on the event object
  • BusService: Call a business service method
There are many examples in bookshelf which describe creating an action set to call a built-in business service such as Workflow Process Manager.

However when it comes to calling your custom written business service method, then you find a note that you have to use the "Context" property to pass the arguments.

What happens when the action is executed is that the Siebel framework creates a property set which contains information about the runtime event and the content of the context field as a string.

We can use the EAI XML Write to File business service and its WritePropSet method to send the input property set to a file. This is what the file looks like when your business service is called from an action set:

click to enlarge
The action set passes the following information:
  • Object Name: The name of the object experiencing the event
  • Business Component Name: The current active BC
  • Context: The content of the Business Service Context field
  • Action Set: The name of the action set
  • Event Type: The type of event (BusComp, Applet or Application)
  • EventId: The ROW_ID of the event
  • Sub Event: The content of the Sub Event field (usually a method or field name)
  • Action: The name of the action
  • Event Name: The name of the event such as PreWriteRecord, etc....
The developer can now write appropriate code to peruse this information in the business service. Usually you would be most interested in the Context property which normally contains something like the following:

"Param1", "Value1", "Param2", "Value2"

This is how it is used for standard business services like Workflow Process Manager. Note that the syntax contains strings in double quotes and they are separated by a comma and a space. Of course, for your custom written business service, you could use any other syntax but this may not be "close to the standard" and could cause problems in larger projects where other developers would not be aware of a different context string syntax.

So basically you have to split the string into the distinct values. Here is a code snippet which gives you the general idea:

//read the string from the input property set
var context_string = Inputs.GetProperty("Context");

//the split method creates a char array, we use comma and space as the delimiter
var context_array = context_string.split(", ");

//now we can get the parameters and values, the odd indexes contain the values
//use for() loops for larger arrays...
var param1 = context_array[1];
var param2 = contaxt_array[3];

//use the replace() function to cleanse the double quotes from the string //the replace() function uses regular expressions which are a little tricky //see examples here param1 = param1.replace(/\"/g,''); param2 = param2.replace(/\"/g,'');

happy scripting ;-)

October 18, 2008

Encounter with the Read CSV File Business Service

still going strong

Sometimes you stumble across a promising Business Service in Siebel Tools, such as Read CSV File. Of course you do a bookshelf search...a Google search...but did you search in Siebel Tools?

What about using the Flat tab and querying the WF Step object type?

Currently there are two standard workflow processes that use the Read CSV File business service

  • Import Marketing Contact
  • Import KPIs
So, interestingly enough, Siebel engineers use the Read CSV File business service to import data into Siebel.

Let's take a look at the Import Marketing Contact workflow.


This workflow is invoked when marketing campaigns are loaded. For more information on this functionality, please refer to the Siebel Marketing guides in bookshelf.

Obviously the data for the marketing members comes as a csv file, which is btw generated by the Oracle BI Presentation Server using a Marketing List Format.

Inspecting the Campaign Load Formats in the default presentation catalog delivered with Oracle BI Applications and/or studying the documentation on Campaign Load Formats reveals, that the csv files have very specific content in the first two rows.

First Row:

a hash sign followed by a space (!) and the name of an integration object
Example: # Internal Account Interface

Second Row:

a hash sign followed by a comma separated list of integration component field names, using double quotes and dot notation.
Example: #"Account.Name","Account.Location","Account.Primary Organization"

Everything from the third row onward is interpreted as data.

So a simple test file could look like this:

Now let's bring up the good old Business Service Simulator.

We are invoking the CsvToPropSet method with the following inputs

CsvFileName = path to test file
DeleteFile = false (default is true, so we set it to false in order not to lose our test file ;-)


The output property set contains a SiebelMessage and a SiebelMessageError child property set, the latter being filled with "bad records" (if any). The SiebelMessage is generated according to the integration object, which acts as a template. This even works with denormalized data, that is you could have the same account name 5 times in the csv file and have a different address each time.

When you write the output property set to an XML file it looks like this:

In a final test step, we move the output to the input and delete the SiebelMessageError child property set from the test case. Then we run EAI Siebel Adapter using its Insert method and voilá, 3 new accounts appear.


Hopefully, this gives you a basic idea how the Read CSV File business service works. As it is used in vanilla workflows, it should be safe to use but due to several reasons I have to put a word of caution here:

Please verify with Oracle Sales if you are licensed to use the Read CSV File business service in production.

Please pay special attention when using non-documented business services as you might not get support from Oracle.

have a nice day

October 22, 2008

Googlin' Bookshelf

file under: rtfm

Know that feeling of getting stuck while searching the pdf version of Siebel Bookshelf?

Want to use your favorite search engine to look for that specific string?

Since Oracle has put all of its documentation - including Siebel Bookshelf - online on OTN, the search bots of Google and the like have happily parsed them and so it's now a part of the index databases of the internet giants.

The following is a Google example, using the site: keyword to narrow the search to Siebel Bookshelf 8.0, but it should work in other search engines as well.

First thing is to verify the base URL for the bookshelf by simply browsing to a document in OTN. Doing so you find that the base URL for Siebel Bookshelf 8.0 is

download.oracle.com/docs/cd/B40099_02

Now let's open Google and type in your query, for example

"EAI Siebel Adapter" site:download.oracle.com/docs/cd/B40099_02
(of course you can bookmark this for later use)

Et voilá: all results for "EAI Siebel Adapter"


Works for Oracle BI, Oracle Database, you name it ;-)

have a nice day

October 26, 2008

Fumbling around with the Oracle BI Message Database

not that quickly

There is a high number of posts and documentation available on the internet on how to customize the Oracle BI EE User Interface (example here), namely the content of the xml or other files (css, etc) that make up the Oracle BI message database. More commonly known as the msgdb folders.

Storing strings and configuration information in easy-to-change text files is of course a benefit but also a curse. Because unlike information stored in a relational database (such as the Siebel CRM repository) it can not be easily merged during an upgrade to a higher release.

So simply overwriting the existing files is not an option as an upgrade would just replace the files with newer versions. To avoid this there is a simple but efficient strategy: Copy the files to a custom folder.

The trick is that the Oracle BI Presentation service loads the messages from several folder locations in a specific sequence which is revealed below:

  1. OracleBIData\web\msgdb\l_xx\customMessages
  2. OracleBIData\web\msgdb\l_en\customMessages
  3. OracleBIData\web\res\customMessages
  4. OracleBI\web\msgdb\l_xx\messages
  5. OracleBI\web\msgdb\messages
l_xx in the above list stands for the language specific folders.

Standard (vanilla) files typically reside in the OracleBI folders, customers are encouraged to copy these files to the OracleBIData folders.

So when you want to change the content of a specific string such as "My Dashboard" you would do a text search in the OracleBI folder and find the uimessages.xml file.

Before manipulating the file you need to copy it to the OracleBIData\web\msgdb\l_en\customMessages folder (create the folder if it does not yet exist).

Now you can safely make changes to the file and restart the Oracle BI Presentation service to verify your changes.

October 30, 2008

Data Lineage in Oracle BI EE

Earlier this year, I had the opportunity to work in a small Oracle BI EE project with a not so small source database. One of my tasks was to enable the project team members to easily identify objects with specific indications such as long-running queries or a high number of requests or a redundancy problem or the like.

To put it short, what they wanted was: Data Lineage for Oracle BI metadata
The design - and later implementation - included the following

  • Oracle BI Usage Tracking (standard module)
  • combined with presentation catalog metadata
  • combined with rpd metadata
There were some obstacles on the way, as usual.

First, the Oracle BI rpd file is, well, a file and the data is not accessible like in a relational database. A fact which has been subject to criticism in recent times. The same holds true for the presentation catalog which has its information spread across thousands of small xml files.

To overcome this, we used the Repository Documentation utility of the Oracle BI Administration Tool. This allows you to create a flat csv file with the dependencies of all objects from presentation layer, business model and mapping layer and physical layer. The screenshot shows the file after the insertion of a primary key column, which is a necessary task if you wish to connect to it as a data source in Oracle BI. In the project we used an import package to load the file into a MS SQL Server database.


You can do the same with the presentation catalog using the Create Report option in the Tools menu of the Catalog Manager.

Both tasks are purely manual and up to this moment I have not found an automation solution for it (if you did, please drop a comment), which is the main reason why data lineage for Oracle BI is a little bit cumbersome. Whenever the rpd or catalog content changes, an administrator must manually extract the csv files and (ideally) load them into tables in a relational database.

As one commenter to this post has found out, there is an execution plan named Data Lineage in the current DAC repository (as created by the installer for Oracle BI Applications 7.9.5). A short investigation reveals that there are indeed table definitions which supposedly hold the data from the rpd and presentation catalog. At the moment this is only in the DAC repository and there is no accompanying ETL mapping in the Informatica repository. I would be so glad to be wrong here - if so, please add your comments below.

Data Lineage subject area (inactive by default) in DAC
We will see what future versions of Oracle BI Applications bring. Maybe a mapping which loads the csv files into the tables along with a ready-to-use rpd file (just dreamin'...)

Now comes the knitting, which means that you have to create complex (physical) joins to glue the rpd metadata together with the presentation catalog data. For a first test you can use the presentation layer object names (table and column) to get first results in Answers. (This post does not deal with the creation of the business model and presentation layer in the rpd file to access the data).

The S_NQ_ACCT table holds the valuable data from Oracle BI Usage Tracking, it has a column which contains the request path which allows us to join it to the presentation catalog data.

Now we have a somewhat complete data lineage tool. Below is a screenshot from one of the first dashboard prototypes of the a/m project which allowed us to visualize the benefits of caching.


There would be more to tell and maybe I find the time to post more on this, but let's dream with me a little more...

What about bringing in the DAC repository, the Informatica repository, the Siebel CRM repository (right-click on a Siebel applet and see a report which describes all BC fields, columns and tables and their mapping to Oracle BI)...whoa...just woke up

have a nice day

About October 2008

This page contains all entries posted to Siebel Essentials in October 2008. They are listed from oldest to newest.

September 2008 is the previous archive.

November 2008 is the next archive.

Many more can be found on the main index page or by looking through the archives.

Powered by
Movable Type and Oracle