mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-29 02:52:13 +00:00
UUIDStringToNum/UUIDNumToString: enforce second parameter to be constant
This commit is contained in:
parent
ee7f862155
commit
a4a6581be3
@ -174,6 +174,7 @@ public:
|
||||
}
|
||||
|
||||
bool useDefaultImplementationForConstants() const override { return true; }
|
||||
ColumnNumbers getArgumentsThatAreAlwaysConstant() const override { return {1}; }
|
||||
|
||||
ColumnPtr executeImpl(const ColumnsWithTypeAndName & arguments, const DataTypePtr &, size_t /*input_rows_count*/) const override
|
||||
{
|
||||
@ -252,6 +253,7 @@ public:
|
||||
}
|
||||
|
||||
bool useDefaultImplementationForConstants() const override { return true; }
|
||||
ColumnNumbers getArgumentsThatAreAlwaysConstant() const override { return {1}; }
|
||||
|
||||
ColumnPtr executeImpl(const ColumnsWithTypeAndName & arguments, const DataTypePtr &, size_t /*input_rows_count*/) const override
|
||||
{
|
||||
|
@ -0,0 +1,2 @@
|
||||
3"\0UDwfˆ™ª»ÌÝîÿ
|
||||
a/<@];!~p{jTj={) 403c2f61-3b5d-7e21-707b-6a546a3d7b29
|
@ -1 +1,4 @@
|
||||
SELECT UUIDStringToNum('00112233-4455-6677-8899-aabbccddeeff', materialize(2)) -- { serverError ILLEGAL_COLUMN }
|
||||
SELECT UUIDStringToNum('00112233-4455-6677-8899-aabbccddeeff', 2);
|
||||
SELECT UUIDStringToNum('00112233-4455-6677-8899-aabbccddeeff', materialize(2)); -- { serverError ILLEGAL_COLUMN }
|
||||
SELECT 'a/<@];!~p{jTj={)' AS bytes, UUIDNumToString(toFixedString(bytes, 16), 2) AS uuid;
|
||||
SELECT 'a/<@];!~p{jTj={)' AS bytes, UUIDNumToString(toFixedString(bytes, 16), materialize(2)) AS uuid; -- { serverError ILLEGAL_COLUMN }
|
||||
|
Loading…
Reference in New Issue
Block a user