github.com/pingcap/ticdc@v0.0.0-20220526033649-485a10ef2652/tests/_utils/run_sql_file (about)

     1  #!/bin/bash
     2  # parameter 1: path to sql file
     3  # parameter 2: database host
     4  # parameter 3: database port
     5  
     6  set -e
     7  
     8  echo "[$(date)] Executing SQL: $1" > "$OUT_DIR/sql_res.$TEST_NAME.txt"
     9  mysql -uroot -h$2 -P$3 --default-character-set utf8mb4 -vv < "$1" >> "$OUT_DIR/sql_res.$TEST_NAME.txt"