Forum Discussion

Einomi's avatar
Einomi
Icon for Helper V rankHelper V
4 years ago
Solved

Extract Text before "("

Dear Community

 

I would like a M code to help me identify "(" in my string then extract the text before it

 

For example, I have the following function in Excel

 

=REDUCE(A2,CHAR(SEQUENCE(26,,65,1)),LAMBDA(x,Y,SUBSTITUTE(x,Y,"')))

 

With Power Query I would like the list of all the functions that were used to write it

 

My expected result should be, a list with the follwing records

 

REDUCE

CHAR

SEQUENCE

LAMBDA

SUBSTITUTE

 

Thanks for your time

9 Replies

  • Vijay_A_Verma's avatar
    Vijay_A_Verma
    Icon for Most Valuable Professional rankMost Valuable Professional

    Equivalent function in PQ is (Data is your column name here)

    = Text.Combine(List.RemoveItems(Text.ToList([Data]),{"A".."Z"}))
  • Thanks Vijay_A_Verma 

     

    However, I am not looking for the equivalent in PQ ðŸ˜Š

     

    I would like the list of the functions used (obviously the final goal was not the function itself but rather an example)

    • Einomi's avatar
      Einomi
      Icon for Helper V rankHelper V

      Hi mussaenda 

       

      I teste with a few formulas, it should work, any issues I'll let you know but for now I will mark this as resolved

       

      Thanks for your assistance