web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Microsoft dynamic crm rest API fetch data by grouping records and with max date to filter duplecate records

(0) ShareShare
ReportReport
Posted on by 55

I am trying to fetch records from CRM entity with restapi 

But i am not finding any way to perform group by dates and to filter records and keep the one with latest creation date.

$select=_aga_availabilityprofile_value,_aga_requireduser_value,_aga_assignedtoteam_value,scheduledend,scheduledstart,activityid&$filter=_regardingobjectid_value eq null and  (statecode eq null or  statecode eq 0)&$orderby=scheduledstart asc

i tried using fetch xml also but for date fields it is giving error

Can anyone help me.

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Dynamics365 Rocker Profile Picture
    7,755 on at

    Below post is about fetch xml and it is similar to your problem:

    community.dynamics.com/.../215742

  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi Divya,

    Check below reference -

    docs.microsoft.com/.../query-data-web-api

    You can also try with CRMRESTBuilder.

    github.com/.../CRMRESTBuilder

  • Suggested answer
    RaviKashyap Profile Picture
    55,410 Moderator on at

    Hi Divya,

    Can you share more details about your requirement? There are several tools in XRM toolbox which you can use to build the fetch xml - Try Fetch XMl builder to build you xml.

    You can then use Rest Builder tool to execute the fetch -

    carldesouza.com/dynamics-crm-rest-builder

    Hope this helps.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans