Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
nareshthavidishetty
Creator III
Creator III

Set analysis

Hi,

We need the data between the date ranges.Below is the logic which is not getting results.Please provide the right expresiion.

=sum({$<AuditDate >={'9/1/2016'}<={'9/3/2016'}>}PostedSales)

Thanks..

1 Solution

Accepted Solutions
sunny_talwar

I still don't think it would work, for my solution to work, in addition to adding ending double quote, I will need dollar sign expansion:

=Sum({$<AuditDate = {"$(='>=9/1/2016<=9/3/2016')"}>} PostedSales)

but why go through all that hassle, when we can just do what you proposed

View solution in original post

14 Replies
sunny_talwar

May be try this:

=Sum({$<AuditDate = {">='9/1/2016'<='9/3/2016'}>} PostedSales)

nareshthavidishetty
Creator III
Creator III
Author

Hi Sunny,

It's showing no results..

Thanks..

sunny_talwar

How is AuditDate formatted?

trdandamudi
Master II
Master II

May be try  this:

=Sum({$<AuditDate = {">=9/1/2016<=9/3/2016"}>} Sales)

sunny_talwar

Yes, I should have not added the single quotes

trdandamudi
Master II
Master II

Sunny,

Is it because the double quote ( " ) is not closed :

=Sum({$<AuditDate = {">='9/1/2016'<='9/3/2016'}>} PostedSales)


May be like below ?

=Sum({$<AuditDate = {">='9/1/2016'<='9/3/2016' "}>} PostedSales)

sunny_talwar

I still don't think it would work, for my solution to work, in addition to adding ending double quote, I will need dollar sign expansion:

=Sum({$<AuditDate = {"$(='>=9/1/2016<=9/3/2016')"}>} PostedSales)

but why go through all that hassle, when we can just do what you proposed

sunny_talwar

Or may be it would work without dollar sign expansion also, I am confused and will have to test it out. But I guess I usually don't even use hard-coded values.

trdandamudi
Master II
Master II

You are right, adding double quote not worked... but I also tried dollar sign expansion as below but no luck.. I thought this will work....

=Sum({$<AuditDate = {"$(='>=9/1/2016<=9/3/2016')"}>} PostedSales)