简体   繁体   English

如何将Word文档中的数据提取到MySQL表中?

[英]How do I extract data from a Word document into a MySQL table?

I have a set of word documents that contains trivia questions in a question/answer format. 我有一组Word文档,其中包含问题/答案格式的琐事问题。 I want to be able to extract these from the word document into a database format such as JSON, CSV, or MySQL with a question column and an answer column. 我希望能够从Word文档中将它们提取到具有问题列和答案列的数据库格式(例如JSON,CSV或MySQL)中。 How would I go about doing this? 我将如何去做呢? (Script?) (脚本?)

The best solution will be to parse the .doc file and store it in comma separated file and then you can import it in MYSQL. 最好的解决方案是解析.doc文件并将其存储在逗号分隔的文件中,然后可以将其导入MYSQL。 The parsing depends on the format(delimiters used) of your word document file. 解析取决于Word文档文件的格式(使用的分隔符)。

可能会有点晚,但是您可以将单词表复制到excel,然后使用https://convertexcel.net/将其转换为JSON,CSV或HTML

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM