Editing XML in Workflow

May 22, 2007 at 9:37 am

Talking about the Echo method the other day I mentioned that you can use dot notation to get at property set elements, but this is such a useful tactic that I think it’s worth revisiting.

Dot notation is what Siebel call your fairly standard ‘parent.child.grandchild’ notation. Imagine a workflow with a hierarchical process property called Employee, which has assigned to it a property set with the properties Login and Password. What dot notation allows you to do is access that Login property directly, by reference to Employee.Login. Simple enough.

This notation works both ways – so you can both retrieve and set properties. To set a property using the Workflow Utilities.Echo method, you need to have the top-level hierarchical process property assigned in the first input variable and then child properties in following variables. As an example: we want to set up the simple Employee Property Set above. We already have the LoginString in a process properties and want the Password ‘geenoos’. Create a Workflow Utilities.Echo step and assign the input variables:

Input Argument Type Value Property Name
Employee Process Property   Employee
Employee.Login Process Property   LoginString
Employee.Password Literal geenoos  

Next – as I’m sure you’ve worked out – if your Employee property set has a child property set, lets say a child PS with a type of Address and properties Street and Postcode, then the Employee’s Street can be accessed with Employee.Address.Street. You can also get at the Property Set’s Value argument, using the notation property.<Value>, which also works at all levels of the hierarchy.

This is all great, useful stuff, but the real kicker comes when you’re working with XML. XML hierarchies in Siebel are just property sets, with attributes as properties and elements as <Values>. By using dot notation in input arguments, output argument and Echo steps, you can construct and edit XML hierarchies on-the-fly, something that previously was impossible without scripting.

The one limitation of dot notation is the 75-character limit to a workflow step argument. This can kick in fairly quickly when you’re dealing with all the ListOfBusinessComponent hierarchies. The workaround is to assign a sub-hierarchy to a secondary process property, do your manipulation, then assign it back in.


Entry filed under: Siebel, Workflow.

Extract all repository tables Sydney Siebel Meetup


%d bloggers like this: