coldfusion example
Feb. 3rd, 2015 02:57 pmstring manipulation -
left(event_desc,iif(find(".",event_desc,100) eq 0,500,find(".",event_desc,100)
return the following string from event description -
if the leftmost 100 characters of the text contains a period and is the only period within the first 500 characters, give the text up to the period, otherwise, return the text up to the second period.
Nicely done – saves having to run a loop or step function.
Originally published at The Scotto Grotto. You can comment here or there.