很奇怪..。最初我认为php没有正确处理大文件上传(800mb-2 2gb)。
现在我已经知道文件被正确地移动了,但是在上传大文件时,将文件信息输入数据库的mysql查询似乎被跳过了。
mysql查询的执行方式与上传小文件时应该执行的一样。这个问题似乎只出现在较大的文件中
此外,在移动文件之前的mysql查询似乎工作得很好。
进程:
Wait for uploaded file,
check file size,
get md5 of file,
move file from temp folder to uploads folder,
if moving file is succes
我想上传一个csv文件,然后显示列有什么。然后我想分配给这个列的mysql表和它的列,以上传内容到数据库。
**CSV -> Upload (HTML Form)**
**show CSV columns like**
| select table and show columns in select combo
-----------------------------------------------------------
id | dropdown with mysql tabel columns
--------------
如何使用php将csv文件正确上传到mysql数据库?
我在phpmyadmin中有一列(已上传,列名),在此列中将存储上传的csv文件。
我有一个上传csv文件到mysql数据库的小脚本,但我得到一些错误"404:文件找不到“后,我点击提交按钮和csv文件没有保存在数据库中。
下面是包含html的php文件:
<?php
include "dbase.php"; //Connect to Database
$deleterecords = "TRUNCATE TABLE contracts"; //empty the table of its c