If you know the filenames, you can try something along the lines of:
SELECT process
FROM table_name
WHERE batchname IN ('batchname1', 'batchname2,', 'batchname3', 'batchname1000');
Now, the problem is that you'll have to come up with a way to put those dynamically in the
WHERE
clause, writing 1000 file names would be painfully boring (not to mention the fact that they may be 10,000 tomorrow).