- Posts: 53
- Thank you received: 2
Drop Records based on a date in a Field
5 years 5 hours ago #18666
by sampelje
Drop Records based on a date in a Field was created by sampelje
Hi,
How might I discard records that have a field called "rundate" where the rundate is more that 7 days of the current date?
Thanks!
How might I discard records that have a field called "rundate" where the rundate is more that 7 days of the current date?
Thanks!
Please Log in or Create an account to join the conversation.
5 years 5 hours ago #18667
by admin
Mike
ETL Architect
Replied by admin on topic Drop Records based on a date in a Field
Hello
Calculate the difference between rundate and current date using the datediff function.
www.etl-tools.com/wiki/aetle/transformat...tions/date/date_diff
to get current date use "Current date" transformation function
www.etl-tools.com/wiki/aetle/transformat...ns/date/current_date
Then use "Is number more than" to discard the records
www.etl-tools.com/wiki/aetle/validation_rules/numbers
Calculate the difference between rundate and current date using the datediff function.
www.etl-tools.com/wiki/aetle/transformat...tions/date/date_diff
to get current date use "Current date" transformation function
www.etl-tools.com/wiki/aetle/transformat...ns/date/current_date
Then use "Is number more than" to discard the records
www.etl-tools.com/wiki/aetle/validation_rules/numbers
Mike
ETL Architect
Please Log in or Create an account to join the conversation.