Skip to main content

ARRAYS_ZIP

Introduced or updated: v1.2.690

Merges multiple arrays into a single array tuple.

Syntax

ARRAYS_ZIP( <array1> [, ...] )

Arguments

ArgumentsDescription
<arrayN>The input ARRAYs.
note
  • The length of each array must be the same.

Return Type

Array(Tuple).

Examples

SELECT ARRAYS_ZIP([1, 2, 3], ['a', 'b', 'c']);
┌────────────────────────────────────────┐
│ arrays_zip([1, 2, 3], ['a', 'b', 'c'])
├────────────────────────────────────────┤
[(1,'a'),(2,'b'),(3,'c')]
└────────────────────────────────────────┘
Explore Databend Cloud for FREE
Low-cost
Fast Analytics
Easy Data Ingestion
Elastic Scaling
Try it today