mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-20 00:30:49 +00:00
Remove subset dotProduct from tuple-functions and add dotProduct as an alias to the superset
This commit is contained in:
parent
f426b5f12b
commit
4408714c55
@ -784,7 +784,7 @@ Returns the dot product of two arrays.
|
||||
arrayDotProduct(vector1, vector2)
|
||||
```
|
||||
|
||||
Alias: `scalarProduct`
|
||||
Alias: `scalarProduct`, `dotProduct`
|
||||
|
||||
**Parameters**
|
||||
|
||||
|
@ -521,45 +521,6 @@ Result:
|
||||
└──────────────────────────────────┘
|
||||
```
|
||||
|
||||
## dotProduct
|
||||
|
||||
Calculates the scalar product of two tuples of the same size.
|
||||
|
||||
**Syntax**
|
||||
|
||||
```sql
|
||||
dotProduct(tuple1, tuple2)
|
||||
```
|
||||
|
||||
Alias: `scalarProduct`.
|
||||
|
||||
**Arguments**
|
||||
|
||||
- `tuple1` — First tuple. [Tuple](../../sql-reference/data-types/tuple.md).
|
||||
- `tuple2` — Second tuple. [Tuple](../../sql-reference/data-types/tuple.md).
|
||||
|
||||
**Returned value**
|
||||
|
||||
- Scalar product.
|
||||
|
||||
Type: [Int/UInt](../../sql-reference/data-types/int-uint.md) or [Float](../../sql-reference/data-types/float.md).
|
||||
|
||||
**Example**
|
||||
|
||||
Query:
|
||||
|
||||
```sql
|
||||
SELECT dotProduct((1, 2), (2, 3));
|
||||
```
|
||||
|
||||
Result:
|
||||
|
||||
```text
|
||||
┌─dotProduct((1, 2), (2, 3))─┐
|
||||
│ 8 │
|
||||
└────────────────────────────┘
|
||||
```
|
||||
|
||||
## tupleConcat
|
||||
|
||||
Combines tuples passed as arguments.
|
||||
|
Loading…
Reference in New Issue
Block a user