Solved

Combining expression values

  • 30 November 2022
  • 5 replies
  • 185 views

Userlevel 2
Badge +5

Hello,

I’m trying to combine to strings in the expression builder to one string. I’m unable to get this to work with liquid filters.

I’m probably missing something. Does anyone have a good idea as how to do this? Essentially i want E3=E1+E2.

icon

Best answer by LucasHansson 1 December 2022, 12:59

View original

5 replies

Userlevel 3
Badge +3

Hey Lucas, 

 

This should be pretty straight forward. If you build out another expression you can just place {{ E1.result }}{{ E2.result }} together. Is this not working?

Userlevel 2
Badge +5

Hey Lucas, 

 

This should be pretty straight forward. If you build out another expression you can just place {{ E1.result }}{{ E2.result }} together. Is this not working?

 

Hello Vishal,

 

This was my thought aswell. I tried this but got an error:

 “Invalid Syntax - Invalid return type for expression”

:(

Best regards,
Lucas

Userlevel 3
Badge +3

Ahh got it.. For string outputs you can use quotes to enclose it.

 

'{{ E1.result }}{{ E2.result }}' that helps distinguish regular strings from numbers and boolean outputs. 

Userlevel 2
Badge +5

Ahh got it.. For string outputs you can use quotes to enclose it.

 

'{{ E1.result }}{{ E2.result }}' that helps distinguish regular strings from numbers and boolean outputs. 

Thanks for the suggestion Vishal,

Unfortunately it still returns the error :(

However, when I test the expression it gives me the wished result.. Strange!

 

Userlevel 2
Badge +5

The issue was resolved by using double quotes! ''{{E1.result}},{{E2.result}}''

Reply