I am querying Salesforce through MS-Flow. There are certain date fields in the Salesforce on which I intend to filter my results.
When i use the 'Get Records' action in the Salesforce and apply an ODATA filter on the records
I am getting the following error message:
Salesforce failed to complete task: Message: eStaff_To_Do__c FROM Case WHERE (Data_Migration_Created_Date__c < ^ ERROR at Row:1:Column:8607 value of filter criterion for field 'Data_Migration_Created_Date__c' must be of type date and should not be enclosed in quotes clientRequestId: ec00b7ed-def2-4c74-8c1d-80a6598a4732
The date is in yyyy-MM-dd format in salesforce. Can anyone point me in the right direction to resolve this issue?
Hi @namit_gupta ,
When configuring Filter Query, if the field type is String, you need to add single quotes outside the string value.
Try adding a single quotation outside of the timestamp, as below:
Data_Migration_Created_Date__c lt '2018-12-02'
Please take a try.
Hi @namit_gupta ,
Could you share a screenshot of the action configuration?
Please ensure that the type of the field is eligible.
In addition, you could try not to configure Filter Query, execute Get records action, and observe how this field is displayed in Body.
Then configure the name of this field in Filter Query.
And follow the previous rules, if the comparison parameter is String or Date, need to add single quotes outside.
If this method still doesn't work, you could use Filter array to filter records instead of using Filter Query.
Three Super User rank tiers have been launched!
Features releasing from October 2020 through March 2021
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!