如何通过 phpmyadmin 导入一个非常大的查询? [英] how to import a very large query over phpmyadmin?

查看:24
本文介绍了如何通过 phpmyadmin 导入一个非常大的查询?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我的主机不允许我将文件直接上传到我的 mysql 文件夹我只能通过 phpmyadmin 这样做吗?除了其本机导入功能外,还有其他选择吗,以便我的连接在上传大约 8mb 的查询时不会超时?

if my host does not allow me to upload a file directly to my mysql folder and i can only do so throught phpmyadmin? are there any alternatives aside from its native import feature so that my connection would not time out while uploading a query that's around 8mb?

推荐答案

您可以 gzip 或 bzip 文件,phpMyAdmin 将解压并运行脚本.

you can gzip or bzip the file and phpMyAdmin will decompress and run the script.

否则我过去必须做的是将我的 SQL 拆分为多个文件并单独加载每个文件.您只需在文本编辑器中打开 SQL 文件,向下滚动大约一半,找到语句的开头,然后将其后的所有内容移动到另一个文件中,即可完成此操作.

otherwise what I've had to do in the past is split my SQL into a number of files and load each one individually. You can do this simply by opening the SQL file in a text editor, scroll to about half way down, find the start of a statement and move everything after that into another file.

这篇关于如何通过 phpmyadmin 导入一个非常大的查询?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆