1 Reply Latest reply: May 15, 2014 9:56 AM by Nick Osdale-Popa RSS

    New to Monarch, is there a 'mid' function??

    thorny00 _

      I'm fairly new to Monarch.  Using version 4.05

      Below is some examples of the data I'm working with.  What I what is only the data that is between the {}  the data doesn't always start in the first position and the length of the data between the {} varies in size.

      How can I accomplish this?  Your help and time is greatly appreciated!

       

      B                                                                               

      {BORRINFO.WHICHBORR} = 1                                                                               

      Name: {@days in process}                                                                     

              Formula: CurrentDate-{MTGTERMS.APP_DATE}

        • New to Monarch, is there a 'mid' function??
          Nick Osdale-Popa

          Not sure what version the Extract function was introduced, but you can try this function:

          [font="courier"]Extract(<your field>,"{","}")[/font][/quote]If the Extract is not available in 4.05, then try a double LSplit Function:

          [font="courier"]LSplit(LSplit(<your field>,2,"{",2),2,"}",1)[/font][/quote]This one first splits the field into two groups based on the "{" character and returns the 2nd half. Then it takes what it returns and splits it on the "}" into two parts again, returning the 1st part.

           

          HTH!