Skip to main content
Question

Using Tester Transformer to query Yesterday (Datetime field)

  • October 4, 2017
  • 2 replies
  • 156 views

Forum|alt.badge.img

I am using the following workflow to pass and INSERT in writer all records with datetime "yesterday". Rest all records will be UPDATE based on an ID field. This workflow will be scheduled to run everyday. I am sure my value field to calculate yesterday is not correct! Any guidance will be helpful.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

Forum|alt.badge.img
  • 275 replies
  • October 4, 2017

Hi @schatt15 

if Lst_Updt_Dt_Tester is the date (or datetime) that needs to be yesterday, the Tester/TestFilter condition should be:

@DateTimeFormat(Lst_Updt_Dt_Tester,%Y%m%d) = @DateTimeFormat(@DateTimeAdd(@DateTimeNow(),-P1D),%Y%m%d)

Forum|alt.badge.img
  • Author
  • 6 replies
  • October 4, 2017

@LenaAtSafe, thank you. That worked.