The path where the uploaded file is copied to is something like current_folder_this_script_is_in/files/ The path that is being put into the query should at least end in .../files/ if it is referring to the same location.
The copy(...) statement has error output suppressed with an @ sign. The upload could be failing, which would cause the copy to fail, or the copy could be failing due to a missing folder, or a folder/file permissions problem. The code needs to check for errors as the result of the upload (did the file get uploaded) and check if the copy worked, before attempting to load the file into the database.
Only the .$file. portion of the path/file in the query is surrounded with quotes. The whole path/file needs to be within quotes. From the mysql manual -
LOAD DATA [LOCAL] INFILE 'file_name' INTO TABLE tbl_name ...
Without the LOCAL keyword, the file must be placed within the mysql server's file system and be directly accessible and readable by the mysql server. If this is not the case, you need to use the LOCAL keyword to get this to be able to read the file from where it is accessible by PHP.
The mysql query has no error checking and reporting -
mysql_query($query) or die('Query Failed: ' . mysql_error());