Replacing code in expressions with Excel substitute
Rather than use find replace or the text editor to replace code A with code B...consider using the substitution function in Excel.
I used an expression to populate data from one database to a new database.
This expression was repeated a number of times and would have been time consuming and/or prone to human error to change....the working expression for datafield 1 was a look up as follows....
GetValue(Field1, "Top\" + sYearName + "\" + sQuarterName + "\" + sMonthName + "\" + sWeekName, "Calendar Original")
The substitution function in Excel replaces text from one expression with new text in a text string.
The attached workbook shows a look-up example between two calendars.
I have replaced the rowcode Field1 with all the other fields I needed, then copied the expression back into XACT.
The subsitution function allows you to efficiently replace an expression.
Thanks to Sean Stewart for highlighting this Excel function
Hope this helps
Jon.
|