Running a MySQL Batch File

So I’ve created loads of MySQL .sql files which create database tables, initiate values and define gzillions of stored procedures.

Now I want to run them all in some kind of batch file on a new database instance. Preferably within MySQL Workbench, which is my database development environment.

Do you know how to do that?

Best wishes,
Antony.

@Antony are you trying to run this through Wappler? Typically I would just run these directly in a query window from Workbench (or whatever editor).

Hi there @zbot11… no, I am trying to run it through MySQL Workbench. I’d ideally like to make a .sql file that just runs a series of other .sql files, but I can’t find anything on the internet that talks about doing this!

Ah got it. Are you running a single-tenant application with a db for every customer? Just wondering.

In SQL you would probably do this using sqlcmd. I’m not sure in MySQL, but I bet there’s a similar command line function. Sorry…I’m of no help!