2 Replies Latest reply: May 15, 2014 10:07 AM by Data Kruncher RSS

    Editing data in Monarch model

    Beevej01 _

      I have a need to do a find and replace on the raw data.


      I use Monarch 8 Pro to view and export my data.


      I want to find Header/Appended info and change the details for specific records and save the info in the original format with only the changes in selected fields.


      Is there a way?



        • Editing data in Monarch model
          Olly Bond

          Hello JMan,


          Yes, you can do tricks like this by trapping everything, using a null trap for the detail, then selecting one big field for the whole line, making a calculated field for the changes you need, hiding the original field and exporting the table as fixed width text.


          You'll need to replicate the logic of the traps for your append/header rows in the calculated field to avoid changing detail date, e.g. if you trapped the Append using the letters ABC, then define the calculated field using Extract() or Substr() depending on the floating trap.


          Best wishes,



            • Editing data in Monarch model
              Data Kruncher

              Further to Olly's comments, I'd add that it might be prudent to be sure to disclose your manipulations of original data to whoever is using your end result, as one of Monarch's best features is that is not intended to alter original data in any way, and thus is a very trusted product.


              That said, a calculated Character field with a formula something like this will help you make the substitutions that you need:


              If(InStr("Test ",MyField)>0,Replace(MyField,"Test ","Actual "),MyField)[/CODE]


              In this example, if MyField contains "Test Data", then the calculated field will contain "Actual Data".