Announcements
You can succeed best and quickest by helping others to succeed. Join the conversation.
cancel
Showing results for
Did you mean:
Not applicable

## Count debtors over a certain period

Hey everyone,

I'm having a problem with counting the amount of debtors from the last 28 days.

I have an expression which defines the last 28 days:
If(Today() - Date <= 28 And  Today() - Date >= 0, 1, 0) As Date_IsLast28Days

And I need to show this in a single Text Object.

This is the expression I use in the text object.

=Count({< Date2 = {"Date_IsLast28Days"}>} DISTINCT Debtor)

The expression below is what I used before, but this only gives the amount of debtors from the day 28 days ago. Not the whole period of 28 days ago:

=Count({< Date2 = {"\$(=date(today()-28))"}>} DISTINCT Debtor)

What I need is the amount of debtors from the last 28 days (28 days ago - until - yesterday).

I hope someone can help me out on this one!

1 Solution

Accepted Solutions

Hi,

=Count({< Date2 = {">=\$(=date(today()-28))<=\$(=date(today()))"}>} DISTINCT Debtor)

Regards,

Great dreamer's dreams never fulfilled, they are always transcended.
3 Replies

Hi,

=Count({< Date2 = {">=\$(=date(today()-28))<=\$(=date(today()))"}>} DISTINCT Debtor)

Regards,

Great dreamer's dreams never fulfilled, they are always transcended.
Specialist

try this

for till date and >= last 28 days

=Count({< Date2 = {">=\$(=date(today()-28))"}>} DISTINCT Debtor)

for till yesterday and >= last 28 days

=Count({< Date2 = {">=\$(=date(today()-28))<=\$(=date(today()-1))"}>} DISTINCT Debtor)

MVP

If you have created a flag for the last 28 days, why don't you use that?

=Count({<Date_IsLast28Days = {1}>} DISTINCT Debtor)

Community Browser