From 502d8210649e707e34cc690719c4dbe5d3838ef1 Mon Sep 17 00:00:00 2001 From: kxt1g21 <kxt1g21@soton.ac.uk> Date: Mon, 8 May 2023 10:31:37 +0800 Subject: [PATCH] (Commit message) Create database and table in sql to insert data --- create_database.sh | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100755 create_database.sh diff --git a/create_database.sh b/create_database.sh new file mode 100755 index 0000000..7f060b7 --- /dev/null +++ b/create_database.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +$(/opt/lampp/bin/mysql -u root -e "create database data; use data") + +$(/opt/lampp/bin/mysql -u root -e "use data; create table YoutubeViews(Name VARCHAR(100), Views int(100), DateTime DATETIME DEFAULT CURRENT_TIMESTAMP())") + -- GitLab