ClickHouse/tests/queries/0_stateless/00974_text_log_table_not_empty.sh
Azat Khuzhin 32071ba080 Do not add event_date/event_time condition for system.*_log
Also some of them can be even more simplified, since the system.*_log
are empty most of the time there should not be any conditions at all
(i.e. `query` LIKE and so on).
2020-05-18 21:18:37 +03:00

18 lines
434 B
Bash
Executable File

#!/usr/bin/env bash
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
. $CURDIR/../shell_config.sh
${CLICKHOUSE_CLIENT} --query="SELECT 6103"
for (( i=1; i <= 50; i++ ))
do
${CLICKHOUSE_CLIENT} --query="SYSTEM FLUSH LOGS"
sleep 0.1;
if [[ $($CLICKHOUSE_CURL -sS "$CLICKHOUSE_URL" -d "SELECT count() > 0 FROM system.text_log WHERE position(system.text_log.message, 'SELECT 6103') > 0") == 1 ]]; then echo 1; exit; fi;
done;