-
Notifications
You must be signed in to change notification settings - Fork 15
Home
bwallace edited this page Dec 17, 2012
·
11 revisions
To clear the db:
(at sql prompt):
drop database abstrackr;
create database abstrackr;
Now, to recreate and empty tables in the db:
websetup.py contains the table definitions. Just invoke:
paster setup-app development.ini
To export database to a .sql file:
mysqldump -u root -p abstrackr > dump.sql (you will be prompted for a password)
To import a database from a .sql file:
mysql -u root -p abstrackr < file.sql // (you'll be prompted for a password)
NOTES
On OS X, you need to use mysqld_safe, ie.,
/usr/local/mysql/bin/mysqld_safe
To activate virtual env on OS X, use
source bin/activate