Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Contributor
Contributor

Expression to show stock levels on a date

HI,

I have warehouse data for all pallets received and dispatched over time. this includes the received date, dispatched date and pallet id amongst other fields. i am trying to look at the pallet stock holding on a particular day/week/month in the past in a table or graph and then be able to filter it by customer and product. there is a data bridge in place that has a canonical date loaded and linked through the data tables if that helps.

the following expression returns a number but does not match the longhand exel figures i have

sum(If (CanonicalDate>=RecDate and CanonicalDate<=[Last Used Date],1,0))

I've been through many of the posts on similar subjects but can't get to a solution that works.

any support would be greatfully received.

thanks

Tags (4)
Labels (2)
2 Replies
Highlighted
Digital Support
Digital Support

Re: Expression to show stock levels on a date

Have you tried with Count() instead of Sum()?
Did you get the same wrong numbers?

To help users find verified answers, please don't forget to mark a correct resolution or answer to your problem or question as correct.
Highlighted
Contributor
Contributor

Re: Expression to show stock levels on a date

Hi,

thanks for the suggestion. Count() returns a very similar number to sum(), they are both about 50-70% of the value i'd expect.