Forum Discussion
else if then loop for each value in table/list
Hi katie_bell
Based on your sample, you have cases of space, dot, #(cr,lf), you can use the UI to Trim, Clean, and Replace " " and "." for both [TextBody] and your lookup Signature
Then you need a look up table like this
You can add a custom column to look up sender, note: Name is my look up table
Table.AddColumn(#"Replaced Value1", "Custom", each [a = [TextBody],
b=
Table.AddColumn( Name,"TEST", each Text.Contains(a, [Signature])),
c= Table.SelectRows(b,each [TEST]= true)[SenderNames
]{0}][c])
If you can provide some sample data, I can give you a query you can copy paste to Advanced Editor and see what's happening.
Thanks so much for your assistance Anonymous!
Is there a way I can limit the table to only sender names, and handle the varying signature blocks in my query? I'm hoping the business area that use the report can update it via an Excel spreadsheet that I will use as the source. Having them manage the signature strings will be too prone to error, so I'll need to keep it simple and only as a list of names.
Additionally, removing spaces from the text is not ideal as the data is quite long (the message body) and will also be used to search for other keywords that contain spaces and other characters.
- Anonymous5 years agoNot applicable
take a look at this setting and explain where and how you would like to change it.
i have problems (and now i don't have time to experiment with text editors) to simulate the # (lf, cr).
- Anonymous5 years agoNot applicable
sorry katie_bell I have issue with my laptop. Yes, you can search sender first then match signature (part of it, maybe) as there might be people with same names...I am wondering what is your source, all text in email body only?