locked
Error while applying a formula in power query RRS feed

  • Question

  • Hi All,

    I am trying to create a custom column in power query, everything works good with this formula only when there is no "." in the wohn it is giving me error. How can I handle this ?

    Please help

    [Haus_New] & [wtyp] & Text.Start([wohn],Text.PositionOf([wohn],"."))

    wohn example are : 027.03, 028.01, etc. etc. and the one where I am getting error is 008

    Monday, April 23, 2018 11:55 AM

Answers

  • Hi,

    What value do you want to return when this is no "."? A simpler way to write the expression would be 

    [Haus_New] & [wtyp] & Text.BeforeDelimiter([wohn],".")
    If no "." exists, then [wohn] is returned in the Text.BeforeDelimiter expression.


    Monday, April 23, 2018 1:32 PM

All replies

  • Hi,

    What value do you want to return when this is no "."? A simpler way to write the expression would be 

    [Haus_New] & [wtyp] & Text.BeforeDelimiter([wohn],".")
    If no "." exists, then [wohn] is returned in the Text.BeforeDelimiter expression.


    Monday, April 23, 2018 1:32 PM
  • Great, Thanks @Colin.
    Monday, April 23, 2018 1:58 PM