mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 16:42:05 +00:00
ISSUES-66 add insert into view test
This commit is contained in:
parent
37f9034575
commit
ce2b100deb
2
dbms/tests/queries/0_stateless/00595_insert_into_view.reference
Executable file
2
dbms/tests/queries/0_stateless/00595_insert_into_view.reference
Executable file
@ -0,0 +1,2 @@
|
||||
1
|
||||
test_string
|
19
dbms/tests/queries/0_stateless/00595_insert_into_view.sh
Executable file
19
dbms/tests/queries/0_stateless/00595_insert_into_view.sh
Executable file
@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
||||
. $CURDIR/../shell_config.sh
|
||||
|
||||
exception_pattern="Code: 48.*Method write is not supported by storage View"
|
||||
|
||||
${CLICKHOUSE_CLIENT} --query "DROP TABLE IF EXISTS test.test;"
|
||||
${CLICKHOUSE_CLIENT} --query "DROP TABLE IF EXISTS test.test_view;"
|
||||
|
||||
${CLICKHOUSE_CLIENT} --query "CREATE TABLE test.test (s String) ENGINE = Log;"
|
||||
${CLICKHOUSE_CLIENT} --query "CREATE VIEW test.test_view AS SELECT * FROM test.test;"
|
||||
|
||||
echo `${CLICKHOUSE_CLIENT} --query "INSERT INTO test.test_view VALUES('test_string');" 2>&1 | grep -c "$exception_pattern"`
|
||||
${CLICKHOUSE_CLIENT} --query "INSERT INTO test.test VALUES('test_string');"
|
||||
${CLICKHOUSE_CLIENT} --query "SELECT * FROM test.test;"
|
||||
|
||||
${CLICKHOUSE_CLIENT} --query "DROP TABLE IF EXISTS test.test;"
|
||||
${CLICKHOUSE_CLIENT} --query "DROP TABLE IF EXISTS test.test_view;"
|
Loading…
Reference in New Issue
Block a user