Converting Date Object vs Date Value for Conditional

Hi there,
I have Date node returning the [Object: “value”] date value while from an RSS I get directly the “value” of the date.

I’m trying to filter at RSS blogs posts that occurred in the last 24h for example

The problem is that I’m looking at an object vs a value and I’m not sure how to transform one or the other and which one I should.

Hey @Vince, sorry to hear you’re having trouble. There’s two potential problems I can see here:

First, your expression in the Value 2 field of your IF node ({{$node["Calculate 24 hrs ago1"].parameter["value"]}}) refers to a parameter itself than to its return value. So you probably want to change it to something like {{$json["yesterday"]}} to read whatever is in the yesterday field:

Afterwards, both values have the same format:

The second problem I see here is that your RSS items seem to be from 2021, meaning your condition would result in false for all of them. If you were to read an RSS feed with slightly more frequent updates, your workflow should work as expected, for example:

This looks like so if executed now, with the 8 items posted in the last 24 hours being sent out on the true branch:

Hope this helps! Let me know if you have any questions on this.

1 Like

Thank you! I was having a bit confused between the $node call result coming from the UI vs getting the direct JSON value.

Thanks it solved it!

1 Like

Hi , I have a question , can we modify this date node to calculate 1 hour before current time ? and then run the work flow for every hour?
So basically the cron should run for every hour , and filter only feeds that came in last hour.(Note I already tried static data approach and now I am looking if this particular workflow can be modified. )