Forum Discussion
Filtering Dynamics CRM
Hmm, was trying to test this but can't even get the $select syntax to work. I get the error:
DataSource.Error: Microsoft.Mashup.Engine1.Library.Resources.HttpResource: Request failed:
OData Version: 3 and 4, Error: The remote server returned an error: (400) Bad Request. (Query options $expand, $filter, $orderby, $inlinecount, $skip and $top cannot be applied to the requested resource.)
OData Version: 4, Error: The remote server returned an error: (400) Bad Request. (Query options $expand, $filter, $orderby, $inlinecount, $skip and $top cannot be applied to the requested resource.)
OData Version: 3, Error: The remote server returned an error: (400) Bad Request. (Query options $expand, $filter, $orderby, $inlinecount, $skip and $top cannot be applied to the requested resource.)
Details:
DataSourceKind=OData
DataSourcePath=https://[tenant].crm.dynamics.com/XRMServices/2011/OrganizationData.svc
Which is a bit senseless since all of the things that are mentioned that I cannot do, I'm not doing. My Power Query was simply:
let
Source = OData.Feed("https://[tenant].crm.dynamics.com/XRMServices/2011/OrganizationData.svc?$select=CreatedOn"),
OpportunitySet_table = Source{[Name="OpportunitySet",Signature="table"]}[Data]
in
OpportunitySet_tableHowever, given the error message I am receiving, I am guessing that you cannot use the $filter syntax to pre-filter your ODATA query, which was the path I was headed down:
https://msdn.microsoft.com/en-us/library/hh169248(v=nav.90).aspx
Has anyone figured out how to filter Dynamics API queries to minimize the data being imported? We have a massive amount of data and it takes forever to do anything.