I have a child pipeline that receives instructions from a control file using a dataset. These instructions define what directory to copy files from.
First this child pipeline checks that a file exists via Get Metadata activity on the source folder. It then executes a child pipeline to process the data if one or more childitems are returned from GetMetaData.
In the control dataset, there is also a required Y/N field meaning I can ignore the error if the folder or file does not exist.
If the folder does not exist, the GetMEtadata will fail. If it exists but no files, I get 0 child items. So 2 different things happen for file or folder missing (an error or 0 items).
In either case, I need to route the output of GetMetaData to an IF that checks if the file was required. If not, consume the error and return. If it was required, raise an error.
I can't find a way to raise an error though. Just as important, is there an alternative approach that would work or fit better with ADF V2 design?
Many thanks, Mark.