on 07-22-2008 2:42 PM
Hi,
I had a confusion being am an beginner in xi that what is the actual functionaity done with the combination of SplitByvalue with collapseContext() and splitByvalue() with removeContexts()
thanks
guna
Hi
split by value:
The SplitByValue() function is the counterpart to removeContexts(): Instead of deleting a context, you can insert a context change in the source value queue. You then receive this element for each inserted context change instead
of a top node element.
removeContext
You can use removeContext() to delete all the top contexts for an element. This deletes all top hierarchy levels, so that all elements of the target queue are assigned to a root element of the source queue
collapseContexts
collapseContexts()copies the first value from all contexts to one context. Empty contexts are replaced with an empty string
For examlpe
if your queue has a total of 4 values.
Your queue is:
12
45
context change
1
context change
4
if you use collapse context and split by value your queue will look like this
Your queue will look like this:
12
context change
1
context change
4
if you use remove context and split by value your queue will look like this
Your queue will look like this:
12
context change
45
context change
1
context change
4
Note : if there is a supress in the queue, remove context will ignore it , where as collapse context will replace it with a blank.
Hope this is usefull
Thanks
Saiyog
Edited by: Saiyog Gonsalves on Jul 22, 2008 5:12 PM
Edited by: Saiyog Gonsalves on Jul 22, 2008 5:21 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Guna,
collapseContexts:
Replaces all values within all contexts with an empty string. This is a useful function when used in combination with SplitByValue.
SplitByValue:
Inserts a context change for an element.
removeContexts
Removes all higher-level contexts of a source field. In this way, you can delete all hierarchy levels and generate a list.
Instead of using remove contexts u better to change Context of your source fileds.
Thanks,
Satya Kumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
1. Remove context:
You use remove Contexts () to delete all the top contexts for an element. This removes all top hierarchy levels, so that all elements of the target queue are assigned to a root element of the source queue.
Advanced user-defined functions can import either just one context into the input arrays, or complete queues. Make your selection by selecting or deselecting the Save Entire Queue in Cache checkbox in the function editor.
2. Collapse context:
Using collapse Contexts() puts the first values of all contexts into a context. Empty contexts are replaced with an empty string: This can be useful if an upper-level node is to be created each time a lower-level node exists,
for example. The function is useful in combination with the SplitByValue function.
3. split by value:
The SplitByValue() function is the counterpart to removeContexts(): Instead of deleting a context, you can insert a context change in the source value queue. You then receive this element for each inserted context change instead
of a top node element. However, for this to be possible, the top node source field must be assigned a top node target field and minOccurs must be >0. You can insert a context change in the queue after each value, after each change to the value, or after each tag without a value.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If you haven't come across this blog:
/people/sravya.talanki2/blog/2005/12/08/message-mapping-simplified-150-part-ii
Regards,
Manjusha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.