Block All Records
Hold the presses! The first Alteryx Certified Expert, Jesse Clark has contributed to the CReW macros. There is simplicity here for all to learn from. But first, why block all records? I know that I’ve used the function many times, but how about you? Have you ever wanted to stop all data from being output? Essentially, you want to sample zero records. Oh! That makes everything so clear. Maybe if I suggest a use case, this will make more sense.
You have an input dataset and want to make sure that the output of your process (e.g. macro) contains all of the fields in the same order as the original file. You could use the Block All Records macro and stream that into a UNION tool. Then set the UNION to read #1 first. It is then up to you whether you will auto-configure by Name or manually configure the data. The bottom line is that the incoming data fields are in the same order on output.
Another example use case is where you have a list of files that you’ve already read. If you read this list into a process looking for new files (JOIN with Left output), you might one day want to ignore all read files and rerun the whole set of data. If you Block All Records, then you’ll end up processing all data as new.
Thanks Jesse for the contribution!