Solved

String Parsing and finding a word in Crystal Report

Posted on 2012-03-29
4
374 Views
Last Modified: 2012-06-28
Dear Team,

I have a Oracle CLOB field data which looks like this when I take the field using Crystal Report.

This ticket was submitted by aut Event Manager.Stored token values follow:GUID( MKUMAR057 )DOMAIN( TMATLKTWS1APP002 )SERVICE( TWS )ORIGIN( TWS )OBJECT( J15184 )OBJECTCLASS( SQL_W_USATLKIFSSQ32_001 )PARAMETER ( SQLWKYATLAPP002 )OBJECTLOCATION ( Unknown )FREETEXT( TMATLKTWS1APP002 : SQL_W_USATLKIFSSQ32_001 J15184 has abended in TWS schedule SQLWKYATLAPP002 )

If you check the first bracket starts with a word GUID(someID)
Can I return the someID value in the report using a formula.

The total string length might be long but it always starts with "This ticket was submitted by aut Event Manager.Stored token values follow:GUID( MKUMAR057 )

I have tried with Split and Left Function but unable to achieve what I want until now.
0
Comment
Question by:AnandSahoo
  • 2
  • 2
4 Comments
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
ID: 37784677
I assume for the example you want to return MKUMAR057

Will there ever be ( or ) before the GUID?

Try this

Split(Split({YourField},')')[1],'(')[2]

mlmcc
0
 

Author Closing Comment

by:AnandSahoo
ID: 37786067
No there no ( or ) before GUID.\

I have tested this and its just working fine.

Thank You.
0
 

Author Comment

by:AnandSahoo
ID: 37904034
Dear mlmcc,

The above formula was working till now but sudenly i get some error. It shows some array range error saying value should start from 1 to.......
Can u plz help. The total string size is not always same.it can be of more length but starting format is always same.
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 37904383
That means you have a field with no ) or ( in it.
Try this

If InStr({YourField},')') > 0 and InStr({YourField},'(') > 0 then
     Split(Split({YourField},')')[1],'(')[2]
Else
     "No GUID"

mlmcc
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question