There is a possibility to filter data table using the activity filter data table…Using this activity you can check for some condition, Keep required column values, Delete the columns which are not required!
For example if currency is your first column you can filter using column number with contains operator and writing different currencies with comma seperated.
Thanks for providing the data, may i clarify that the output data for this case would be:
“USD FOMC Rate Decision (Upper Bound) (JUL 31)” High H 2.25% 2.50%
“EUR German Unemployment Change (000’s) (JUL)” High H 1.0k 2.0k 0.0k
“CNY Manufacturing PMI (JUL)” High H 49.7 49.6 49.4
OR
“USD FOMC Rate Decision (Upper Bound) (JUL 31)” High H 2.25% 2.50%
“USD FOMC Rate Decision (Lower Bound) (JUL 31)” High H 2.00% 2.25%
“EUR German Unemployment Change (000’s) (JUL)” High H 1.0k 2.0k 0.0k
“USD FOMC Rate Decision (Upper Bound) (JUL 31)” High H 2.25% 2.50%
“EUR German Unemployment Change (000’s) (JUL)” High H 1.0k 2.0k 0.0k
“CNY Manufacturing PMI (JUL)” High H 49.7 49.6 49.4
I had thought that these were separate columns. Either way, you may try:
order.ToString = row(“Country”).ToString.Split(" "c)(0)
This splits the string by blanks and compares the first word.
PS. You may want to avoid using row(“Country”).ToString.Contains(order.ToString)
If your field is something like “CNY Manufacturing PMI AMATEUR (MAY)”, it will match the case where it contains “EUR”
You can use OrderBy & ThenBy functions with StartsWith method in LinQ.
OrderBy and ThenBy —> to give priorities
StartsWith —> to give condition. like —> OrderBy(Function(a) (a("Country").ToString.StartsWith("CAD"))).ThenBy(Function(b) (b("Country").ToString.StartsWith("AUD"))) and so on.
I’m attaching a zip having sample workflow for your better understanding.