将excel表导入到mysql中最简单的方法是什么? [英] What is the easiest way to import an excel sheet into mysql
问题描述
我的解决方案将导出为csv,并通过php将其放在mysql中,但必须
尽管 mysqlimport
解决方案是绝对可行的,它可能很麻烦( NULL
处理例如,如果你必须导入很多文件,或者你必须定期导入它们。我有时可以使用Toad®for MySQL ,它能够将XLS(X)文件直接导入MySQL。如果您现在只导入一些Excel数据,那么这肯定是过度的 - 但是它是一种替代方法,它可以自动化,因为Toad支持自动化工作流程。
I have an Excel sheet with some cols and i want to import those into the mysql table. The Problem is that there are more colums in the mysql table than in the sheet (which is absolutely fine). What would be the easiest way of getting the data in the right fields?
My solution would be export to csv and put it in mysql via php, but there has to be a way that is more simple.
Although the mysqlimport
solution is absolutely feasible, it can be cumbersome (NULL
handling e.g.) if you have to import a lot of files or if you have to import them regularly. I sometimes use Toad® for MySQL which is able to directly import XLS(X) files into MySQL. This surely is overkill if you only import some Excel data now and then - but it's an alternative and it can be automated as Toad supports automation workflows.
这篇关于将excel表导入到mysql中最简单的方法是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!