Line break to remove if column is blank

My current expression is
CONCATENATE(
if(isnotblank([WASHING]),Concatenate(Washing," - ",[WASHING]),"")&"
"&
if(isnotblank([DAMAGE]),Concatenate(Damage," - ",[DAMAGE]),"")&"
"&
if(isnotblank([Road Fare]),Concatenate(Road," - ",[Road Fare]),"")&"
"&
if(isnotblank([Others]),Concatenate(Others," - ",[Others]),"")
)

For Mr.Steve.jpg

Solved Solved
0 5 102
1 ACCEPTED SOLUTION

Steve
Platinum 5
Platinum 5

Or this:

SUBSTITUTE(
  CONCATENATE(
    LIST(
      IFS((0 <> [WASHING]), ("Washing - " & [WASHING])),
      IFS((0 <> [DAMAGE]), ("Damage - " & [DAMAGE])),
      IFS((0 <> [Road Fare]), ("Road - " & [Road Fare])),
      IFS((0 <> [Others]), ("Others - " & [Others]))
    )
    - LIST("")
  ),
  " , ",
  "
"
)

View solution in original post

5 REPLIES 5

Steve
Platinum 5
Platinum 5

Try this:

CONCATENATE(
  IFS((0 <> [WASHING]), ("Washing - " & [WASHING])), "
  ", IFS((0 <> [DAMAGE]), ("Damage - " & [DAMAGE])), "
  ", IFS((0 <> [Road Fare]), ("Road - " & [Road Fare])), "
  ", IFS((0 <> [Others]), ("Others - " & [Others]))
)

Line break was still there.

For Mr.Steve 2.jpg

Whoops! I misunderstood. Try this instead:

CONCATENATE(
IFS((0 <> [WASHING]), ("Washing - " & [WASHING] & "
")), IFS((0 <> [DAMAGE]), ("Damage - " & [DAMAGE] & "
")), IFS((0 <> [Road Fare]), ("Road - " & [Road Fare] & "
")), IFS((0 <> [Others]), ("Others - " & [Others]))
)

Steve
Platinum 5
Platinum 5

Or this:

SUBSTITUTE(
  CONCATENATE(
    LIST(
      IFS((0 <> [WASHING]), ("Washing - " & [WASHING])),
      IFS((0 <> [DAMAGE]), ("Damage - " & [DAMAGE])),
      IFS((0 <> [Road Fare]), ("Road - " & [Road Fare])),
      IFS((0 <> [Others]), ("Others - " & [Others]))
    )
    - LIST("")
  ),
  " , ",
  "
"
)

It really worked.
Thank my Steve Bro.
I will try to understand this.
Again, Thanks.
It was not a big thing for many but It had been gnawing at me for weeks now.

Top Labels in this Space