Automating Load SQL text file

tomthirteen posted 1 week ago in General


Does anyone know how to automate the loading of an SQL text file in Heidi? I have over 200 interlanguage link SQL text files from Wikipedia which I'd like to load in individual scripts for each database. However, I can't see to find the script for this. There is the drop down option from file, and the "source" command for the mysql command window. But what is the mysql if you are running mysql scripts in HeidiSQL to load this file?

Thanks, Tom

ansgar posted 7 days ago

Click File > "Run SQL file", and select all 200 files. Easy, or?

If you want them to be run in different databases load them one by one, by hand? 200 files should not take too long.

tomthirteen posted 6 days ago

These files are huge. The French interlanguage file is 880 MG and is taking about 20 hrs to insert each item. Isn't what you suggest manual? Is there no MySQL command that I could write into a script? I can't find one that works in Heidi.

Misha v.3 posted 6 days ago

I believe you should use mysql cli instead (you can put it in cron/scheduler if you like).

Please login to leave a reply, or register at first.