Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
qlikeers
Creator II
Creator II

New customers - line chart - set analysis

Is it possible to graph only new customers by month using broad transactional data (fact table plus dimension tables), without using the load editor and using only set analysis? A new customer is one who bought for the first time in a given month and has never bought anything before.

Labels (5)
4 Replies
vighnesh_gawad
Partner - Creator
Partner - Creator

yes, it is possible in Qlik Sense using only set analysis. Check if this expression solve your query.

Count(
    DISTINCT
    Aggr(If(
            MonthStart(Min(TOTAL <CustomerID> TransactionDate))
            = MonthStart(TransactionDate),
            CustomerID
        ),
        CustomerID,
        MonthStart(TransactionDate)
    ))
Regards, Vighnesh Gawad
Connect with me on LinkedIn | GitHub
qlikeers
Creator II
Creator II
Author

Thanks, it seems to show the correct numbers after some adjustments.

I just have one more question: can this be written so that it works correctly also depending on the selection of different dimensions?

vighnesh_gawad
Partner - Creator
Partner - Creator

 

Can you expand on that? The current expression will work based on selections. Right now, it evaluates against the entire dataset, but when users select any dimensions, the expression will recalculate only for the selected data subset.

Do you want any specific behavior when someone clicks on a dimension?

Regards, Vighnesh Gawad
Connect with me on LinkedIn | GitHub
qlikeers
Creator II
Creator II
Author

Currently, the model looks like a star: there's a fact table (transactions) and several dimension tables, such as those for products and calendars.

I'd like it to calculate correctly regardless of the dimension I select in the filter. But I think it might actually work that way now that I think about it.