Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

How to use SETFILTER with OR logical operation.

(0) ShareShare
ReportReport
Posted on by 35

I want to use filter on two fields of the same table with one value.

There are two columns named as posting date and document date and let's suppose I want to get rows having either posting date =TODAY OR document date =Today.

When I use SETFILTER two times it gives me rows having posting date and document date=TODAY.

BUT I want to get all rows whose posting date is TODAY may be document date is different and all rows whose Document date is TODAY may be posting date has different value.

I hope its enough to understand the scenario.

May be there is no possibilities to use OR with SETFILTER but if you Know another way to solve it then feel free to share with me I'll really appreciate that.

Thank you.

*This post is locked for comments

  • Suggested answer
    Suresh Kulla Profile Picture
    46,792 on at
    RE: How to use SETFILTER with OR logical operation.

    Unfortunately you cannot do that with one single fitler, you need to filter on one field get the records and store in temporary or mark them, then again reset and apply the next filter and insert those into temporary/mark.

  • Suggested answer
    HoangNam Profile Picture
    315 on at
    RE: How to use SETFILTER with OR logical operation.

    You can use FILTERGROUP(-1).

    You can reference Page 658 Approval Entries which use MarkAllWhereUserisApproverOrSender method of Table 454 Approval Entry.

    CrossFilter.png

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,998 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,850 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans