Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Issue with $ expansion when space in text input

Hi,

I am having an issue with $ expansion where the text has space (Brand name has space) and is not working. Below is the expression that works when the text in the Brand is single word. But doesn't when it has 2 or more words with a space.

sum

(

{1<

Brand={$(=Brand)}

>}

sales

)

I tried putting the quotes as below (this was suggested in one of the posts but it didn't work)

sum

(

{1<

Brand={'$(=Brand)'}

>}

sales

)

I will try any of your suggestions to resolve this seemingly simple issue.

Thanks,

Deepak

1 Solution

Accepted Solutions
Jason_Michaelides
Luminary Alumni
Luminary Alumni

Your second attempt is almost right!  Use double-quotes instead of single...:

sum({1<Brand={"$(=vBrand)"}>} sales) where vBrand is your variable for brand input.

Hope this helps,

Jason

View solution in original post

4 Replies
Jason_Michaelides
Luminary Alumni
Luminary Alumni

Your second attempt is almost right!  Use double-quotes instead of single...:

sum({1<Brand={"$(=vBrand)"}>} sales) where vBrand is your variable for brand input.

Hope this helps,

Jason

swuehl
MVP
MVP

Interesting,

I would have assumed that Deepak's second expression

sum({1<Brand={'$(=vBrand)'}>} sales)

should work as is

(I personally would have written something like sum({1<Brand={'$(vBrand)'}>} sales)

i.e no equal sign (no dollar sign expansion with an Expression, just a plain variable call) ).

At my site, all 3 expressions do work (in Jason's sample app).

Regards,

Stefan

Jason_Michaelides
Luminary Alumni
Luminary Alumni

Do you know - I swear I tried both Deepak's expression before and it didn't work.  I guess I musn't have though, as all 3 work for me too (that's Deepak's 2nd exp, my exp and Stefan's).

I guess Stefan's straight variable call would be the most efficient.

Jason

Not applicable
Author

Thank you very much. The double quotes did it. - Deepak