25
Views
5
Comments
Two condition in filter?
Question

I have two conditions - which display the report for the last month


Begin Date and End Date 


How can I put them in Filter (ConditionCardAcceptResponse.RequestDateTime) ???????


Rank: #67

Hi there,


You can use the following statement:

DiffDays(AddMonths(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) >= 0 and DiffDays(AddDays (NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) <= 0


Explanation of DiffDays:


Hope it helps.


Cheers,

João


Rank: #2812

João Marques wrote:

Hi there,


You can use the following statement:

DiffDays(AddMonths(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) >= 0 and DiffDays(AddDays (NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) <= 0


Explanation of DiffDays:


Hope it helps.


Cheers,

João


 

 I already have two conditions written (BeginDate and EndDate)


How can they be put in CustomerCardResponse.RequestDateTime (Filter)

Rank: #2812

João Marques wrote:

Hi there,


You can use the following statement:

DiffDays(AddMonths(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) >= 0 and DiffDays(AddDays (NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) <= 0


Explanation of DiffDays:


Hope it helps.


Cheers,

João


 

 

Rank: #67

Hi,


From your question, I understand you want to filter the date if it exists between the BeginDate and the EndDate.

Given that, your filter should be:


DiffDays(AddMonths(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) >= 0 and DiffDays(AddDays (NewDate(Year(CurrDate()),Month(CurrDate()),1),-1), CustomerCardAccepResponse.RequestDateTime) <= 0 


Cheers,

João

Rank: #654

Hi,

You can use below filter condition:

ConditionCardAcceptResponse.RequestDateTime >= AddMonths(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1) 
 and 
ConditionCardAcceptResponse.RequestDateTime <= AddDays(NewDate(Year(CurrDate()),Month(CurrDate()),1),-1) 

Hope this will help you,

Regards,

Vipasha