Retrieve and display data from a string in a cloumn

I want to retrieve data from a list of string which has the data displayed as “@@@@-@@-#####” where @ is an alphabet and # is a number. I want to get the first two numbers and make a column that will sort and display the data according to those numbers. Example of the string could be ABCD-EF-19002, I want to extract 19 and use it in another column called year and sort the data in the report according to the year. How should I do this? the string is an attribute in an entity.
1 answers
  • Add column year to the list of your entity that has the string
  • Loop over the list
  • In the loop get the two digits using Change Object ‘iteratorYourList’ when you set attribute year to:
2000 + substring($iteratorYourList/yourattribute, 8,2)
  • after the loop do activity ListOperation and select operation Sort, list Yourlist and Sorting add field Year