Ok so I posted this question a few minutes ago and the issue regarding that was solved. Now continuing in the direction of that question, I have another problem. The query that inputs the data from the file, inputs it (and very fast if I might add) but then does not stop. Instead it continues to add additional rows of empty data since the rows in the CSV just go on to infinite, and so it just inputs more empty rows to the db. How can I stop this? Is there an eof mark that I can use here or what.