It's all about the answers!

Ask a question

manage string in RRDI


0
1
Elena Purice (111) | asked Nov 05 '13, 12:16 p.m.
Hi all,
I have need your help to understand in RRDI if it is possible to manage a string.
For e.g.: I have the field buildresult="CIAO:1234|ADDIO:5678" and I have need create a string that contains only CIAO - ADDIO and another string with 1234 - 5678.
But I don't know the length the field buildresult because it is enhanced from apposite work item

Could you help me?

Thanks.

Best Regards,

elena

One answer



permanent link
Jackie Albert (1.6k14947) | answered Nov 05 '13, 2:34 p.m.
Hi, I would recommend using the 'substring' and 'postition' functions to create new Data Items with your results.

To get the data after the '|' character, use something like this:
substring([BuildResult], (position ('|', [BuildResult])))

To get the data before the '|' character, use something like this:
substring([BuildResult], 1, (position ('|', [BuildResult])))

This may not work exactly as-is so you might need to tweak as I quickly wrote up an example, but hopefully this will point you in the right direction.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.