This may not work for your specific use case, but incremental transforms enable you to read data from a dataset that you want to write back to later on in the same transform.
Here’s a link to a previous community post regarding how to accomplish this: https://community.palantir.com/t/incremental-transforms-how-to-read-entire-output-dataset-at-start-of-execution/1860/2.