Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

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_michaelid
Honored Contributor II

Re: Issue with $ expansion when space in text input

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

4 Replies
jason_michaelid
Honored Contributor II

Re: Issue with $ expansion when space in text input

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

MVP
MVP

Re: Issue with $ expansion when space in text input

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_michaelid
Honored Contributor II

Re: Issue with $ expansion when space in text input

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

Re: Issue with $ expansion when space in text input

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

Community Browser