AnsweredAssumed Answered

Parsing text

Question asked by galeton on Sep 6, 2012
Latest reply on Sep 6, 2012 by philmodjunk

Title

Parsing text

Post

Hi. I have a database where I am parsing json text. All is going well except one field. I have a field called "publish_date" which represents the copyright date. When the text is imported it looks like this. "publish_date";"1990", My current formula is If(PatternCount ( BOOK::json ; "publish_date" ) = 1 ; parseJSON ( BOOK::json; "publish_date" ; ","  );""). This works well in cases where all I have is the month and year or just the year. But I run into problems when there's a comma in the date such as "Janurary 4, 1990",   The date appears as January 4 because it stops at the first comma. Is there a way to work around this so the date will be parsed correctly whether there is a comma in the date or not? I've spent most of the day trying to figure out a workaround but no luck. Thanks for any help.

 

Outcomes