Forum Discussion

Ennlamp's avatar
Ennlamp
Copper Contributor
Aug 24, 2022
Solved

Total sum from the Text

Hi,   I have a database, where some numeric info is part of the standardized text (column L).  Can you help me with the totals in a separate column (column M). Some of the number in column L are wi...
  • mtarler's avatar
    Aug 24, 2022

    Ennlamp  What I think you want is a number of functions combined.  I have created 4 Lambda functions in the attached workbook and demonstrated them working:

    CleanNumbers - this lambda will see if excel recognizes a value as a number but if not it will swap all the commas and periods and try again and if still not it will return 0

    ExtractNumbers - this lambda will take any string and create an output string of just the 'numeric' values separated by ";" so "test12and(56.34)" will output "12;56.34"

    Txt2Array - this lambda will take a string and delimitator character and create an array (i.e. the output from Extract Numbers and make it an array) (note I believe this is one of those functions in beta already)

    SumNumsFromTxt - this lambda combines all the above into a single function to sum all the numeric values found inside the array of text strings. 

     

Resources