mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-30 03:22:14 +00:00
fix test
This commit is contained in:
parent
212731b3e2
commit
461fb1eaa8
@ -1553,6 +1553,7 @@ private:
|
||||
static std::pair<String, String> parseParameter(const String & s)
|
||||
{
|
||||
size_t pos = s.find('_') + 1;
|
||||
/// String begins with "--param_", so check is no needed
|
||||
/// Cut two first dash "--" and divide arg from name and value
|
||||
return {s.substr(2, pos - 2), s.substr(pos)};
|
||||
}
|
||||
|
@ -9,11 +9,11 @@ ${CLICKHOUSE_CURL} -sS $CLICKHOUSE_URL -d "CREATE TABLE ps (i UInt8, s String) E
|
||||
${CLICKHOUSE_CURL} -sS $CLICKHOUSE_URL -d "INSERT INTO ps VALUES (1, 'Hello, world')";
|
||||
${CLICKHOUSE_CURL} -sS $CLICKHOUSE_URL -d "INSERT INTO ps VALUES (2, 'test')";
|
||||
|
||||
${CLICKHOUSE_CURL} "${CLICKHOUSE_URL}?param_id=1"\
|
||||
-d "SELECT * FROM ps WHERE i = {id:UInt8}";
|
||||
${CLICKHOUSE_CURL} "${CLICKHOUSE_URL}?param_phrase=Hello,+world"\
|
||||
-d "SELECT * FROM ps WHERE s = {phrase:String}";
|
||||
${CLICKHOUSE_CURL} "${CLICKHOUSE_URL}?param_id=2¶m_phrase=test"\
|
||||
-d "SELECT * FROM ps WHERE i = {id:UInt8} and s = {phrase:String}";
|
||||
${CLICKHOUSE_CURL} -sS "${CLICKHOUSE_URL}?param_id=1"\
|
||||
-d "SELECT * FROM ps WHERE i = {id:UInt8} ORDER BY i, s";
|
||||
${CLICKHOUSE_CURL} -sS "${CLICKHOUSE_URL}?param_phrase=Hello,+world"\
|
||||
-d "SELECT * FROM ps WHERE s = {phrase:String} ORDER BY i, s";
|
||||
${CLICKHOUSE_CURL} -sS "${CLICKHOUSE_URL}?param_id=2¶m_phrase=test"\
|
||||
-d "SELECT * FROM ps WHERE i = {id:UInt8} and s = {phrase:String} ORDER BY i, s";
|
||||
|
||||
${CLICKHOUSE_CURL} -sS $CLICKHOUSE_URL -d "DROP TABLE ps";
|
||||
|
Loading…
Reference in New Issue
Block a user