If anyone has searched this, I've found a solution. You need to search through a .txt (or .sql) file line by line and store the lines into an array, then store the array to the table as normal:
$file_handle = fopen("STOCK.TXT", "rb");
while (!feof($file_handle) ) {
$line_of_text = fgets($file_handle);
$parts = explode(';', $line_of_text);
$into = mysql_query($parts[0]);
if (!$into)
{
die('Could not import: ' . mysql_error());
}
}