sqlite-things/script.sh

11 lines
309 B
Bash

#!/bin/bash
if [[ $1 -eq "0" ]]; then
sqlite3 test.db ".read sql/create_db.sql"
elif [[ $1 -eq "1" ]]; then
sqlite3 test.db ".read sql/insert_data.sql"
elif [[ $1 -eq "2" ]]; then
sqlite3 test.db ".read sql/show_sg.sql"
elif [[ $1 -eq "9" ]]; then
sqlite3 test.db ".read sql/show_all.sql"
fi