ClickHouse/tests/queries/0_stateless/01474_custom_null_tsv.sh
2021-10-21 19:42:03 +03:00

16 lines
555 B
Bash
Executable File

#!/usr/bin/env bash
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
# shellcheck source=../shell_config.sh
. "$CURDIR"/../shell_config.sh
$CLICKHOUSE_CLIENT --query="DROP TABLE IF EXISTS tsv_custom_null";
$CLICKHOUSE_CLIENT --query="CREATE TABLE tsv_custom_null (id Nullable(UInt32)) ENGINE = Memory";
$CLICKHOUSE_CLIENT --query="INSERT INTO tsv_custom_null VALUES (NULL)";
$CLICKHOUSE_CLIENT --format_tsv_null_representation='MyNull' --query="SELECT * FROM tsv_custom_null FORMAT TSV";
$CLICKHOUSE_CLIENT --query="DROP TABLE tsv_custom_null";