Jump to content

[Wiki] Easily Import Database Files from zp_world or other (Debian)


Recommended Posts

Posted

Nothing worse then inputting all the queries one by one, so I thought I'd share this with those who have never tried it.

Create a runsql.sh File inside the databases you're creating and your content will look like so inside the SH File.

DBUSER="root"
PASS="mangos"
DB="mangos"
for f; do
         mysql -u $DBUSER -p$PASS $DB <$f
done

Obviously in the DBUSER PASS and DB put your info in.

Open a terminal and then cd to zp_world (or other DB)

Type

sh runsql.sh *sql

Let all the queries in zp_ execute. :)

Nothing fancy, but it's a nice time saver.

Posted

@TheLuda; Is this possibly something that can be implemented into the source so when the users goes to get it up and running they just have to run the shell script and it'll be ready rather then having a one by one manual import?

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use