Commit 1a2a3ddd authored by yiwenshao's avatar yiwenshao

able to backup and restore

parent dce7ff24
name="all.sql"
if [ $# = 1 ];then
name=$1
fi
mysqldump -uroot -pletmein -h127.0.0.1 -P3306 --no-create-info --compact tpcc1000 > $name
mysql -uroot -pletmein tpcc1000 < count.sql
select count(w_id) as warehouse from warehouse;
select count(d_w_id) as district from district;
select count(c_w_id) as customer from customer;
select count(h_c_id) as history from history;
select count(no_w_id) as new_orders from new_orders;
select count(o_w_id) as orders from orders;
select count(ol_w_id) as order_line from order_line;
select count(i_id) as item from item;
select count(s_w_id) as stock from stock;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment