You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-17 09:41:06 +03:00
25 lines
540 B
Bash
25 lines
540 B
Bash
#!/bin/bash
|
|
|
|
#
|
|
# Functions that make mysql calls used by some of the nightly test scripts.
|
|
#
|
|
|
|
#
|
|
# This function outputs the count from the passed sql statement.
|
|
# Parameters:
|
|
# db - the database
|
|
# sql - the sql statement
|
|
#
|
|
# Example:
|
|
# liCount=`getCount tpch1 "select count(*) from lineitem;"`
|
|
#
|
|
getCount()
|
|
{
|
|
# The awk in the result is a hack for cygwin to avoid arithmetic expression errors and jumbled wrapping in the status
|
|
# output.
|
|
db=$1
|
|
sql=$2
|
|
$MYSQLCMD $db -e "$sql" | tail -1 | awk '{print $0}'
|
|
}
|
|
|