Author |
Message |
jline
Newbie
Joined: 03 Apr 2014
Location: Australia
Online Status: Offline
Posts: 3
|
Topic: Splitting a string into separate field values Posted: 03 Apr 2014 at 2:55pm |
Hi All,
I am currently in the middle of doing a report, and have been stuck on this for quite some time.
I'd like to split a string into separate field values. They are currently separated by spaces.
Summary Fields can vary, e.g. "Adobe Facebook Photoshop Reader"
A ticket number is the main identifier, and they are all linked to this.
At the moment, the output is:
TicketNumber1 Adobe Facebook Photoshop Reader
The desired output would be:
TicketNumber1 Adobe
TicketNumber1 Facebook
TicketNumber1 Photoshop
TicketNumber1 Reader
Any help is much appreciated. Thanks
|
IP Logged |
|
kostya1122
Senior Member
Joined: 13 Jun 2011
Online Status: Offline
Posts: 475
|
Posted: 04 Apr 2014 at 11:45am |
something like this should work left( your_field,instr(instr(your_field," ") +1 ,your_field," "))
|
IP Logged |
|
jline
Newbie
Joined: 03 Apr 2014
Location: Australia
Online Status: Offline
Posts: 3
|
Posted: 06 Apr 2014 at 1:21pm |
Hi,
Thanks for your reply. But that's not giving the desired output. There are no errors, however, it's not even returning the first desired field of "Adobe".
|
IP Logged |
|
jline
Newbie
Joined: 03 Apr 2014
Location: Australia
Online Status: Offline
Posts: 3
|
Posted: 10 Apr 2014 at 2:20pm |
Bump
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 11 Apr 2014 at 3:53am |
do you really need this in different fields or just in a format like the above, as in a text box with line returns in it? Even if it is in different fieds it is still going to be part of the same detail row, it will not create new rows of data.
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 11 Apr 2014 at 3:59am |
{ticketnumber} + " "+ replace({String}," ",(chr(13)+ {ticketnumber}+" "))
|
IP Logged |
|
|