Don Panek Posted November 8, 2018 Share Posted November 8, 2018 Hi All. A client is having a very odd problem with fetch block in a map. Here is scenario - the connection is D365 Fetch appointments where owner = x and actualclosedate > yesterday -1day and actualclosedate < yesterday +1 day (trying to generate a report that pulls all appointments closed on yesterday. When I look at debug, the queries all look right, yet the fetch only returns 1 record when there are actually 4 in D365 An advanced find in D365 for appointments where owner = x and actualclosedate = yesterday yields 4 records as it should. Anyone have any similar issues Apparently using the formula of actualclosedate = yesterday doesnt work, hence the greater than and less than Seems like no matter what formula we use the result of the fetch is not accurate. Any help would be appreciated. Thanks Don Link to comment Share on other sites More sharing options...
Brandon Olwage Posted September 23, 2019 Share Posted September 23, 2019 I was having a similar issue with lookups. It was only after I had specified my dataAreaId that it returned multiple records. Also if you are looking for appointments from yesterday then try this formula: actualclosedate = DATEADD("d", -1, GETDATETIME()) Link to comment Share on other sites More sharing options...
Donald Johnson Posted October 9, 2019 Share Posted October 9, 2019 While troubleshooting / debugging your formulas/filters, you could try adding a rough filter date range such as all closedates older than "yesterday-1day" and withing your FETCH block loop, you can fine tune your filter by using an IF block that furthers filter out the exact date range that you need for your target mapping operations(Create / Delete/ Update etc). PS: I would like to apologize to who ever answer this really is. We have a new tool to move comments to answers and visa versa. The real answerer answered in a comment. I went to move it to answers. But I now own the answer. Sorry to the real answerer. If you are that person, you can email me, donjohns@tibco.com , and I'll give it back to you. Link to comment Share on other sites More sharing options...
Ash Arendsz Posted October 9, 2019 Share Posted October 9, 2019 I meant to say: closedates "younger" than "yesterday-1day" Link to comment Share on other sites More sharing options...
Ash Arendsz Posted October 9, 2019 Share Posted October 9, 2019 While troubleshooting / debugging your formulas/filters, you could try adding a rough filter date range such as all closedates youngerthan "yesterday-1day" and withing your FETCH block loop, you can fine tune your filter by using an IF block that furthers filter out the exact date range that you need for your target mapping operations(Create / Delete/ Update etc). PS. DonJohnson, thanks for the headsup. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now