Hi, I have 3 to 6 rows of multi-line text (ending in Carriage Return) in Comment field which i want to split into separate fields E.g.
Salesperson: AA
Cust PO: 12345
Cust PartNum: WQ6789
…
Result required in separate fields:
Comment1 Salesperson: AA
Comment2 Cust PO: 12345
Comment3 Cust PartNum: WQ6789
…
How do I do in baq?
Thanks in advance
Derrick
Make calculated fields, using substrings of the original field. Use search
Charindex to find your CR’s, to determine the lengths and positions of the substrings.
There may even be a ‘split’ function in sql. Research that.
Edit
Found this
Substring(FullName, 1,Charindex(',', FullName)-1)
That extracts the first part of field FullName ( comma separated)