# CONCAT

> CONCAT function in StackQL: join any number of values into one string, skipping NULL arguments.

Source: https://stackql.io/language-spec/functions/string/concat

Concatenates its arguments into one string.  `NULL` arguments are skipped, unlike the [`||` operator](/language-spec/functions/string/concatenation), which returns `NULL` when either operand is `NULL`.

See also:  
[[` SELECT `]](/language-spec/select) [[` CONCAT_WS `]](/language-spec/functions/string/concat_ws) [[ Concatenation ]](/language-spec/functions/string/concatenation)

* * * 

## Syntax

```sql
SELECT CONCAT(value [, value ...]) FROM <multipartIdentifier>;
```

## Arguments

__*value*__  
One or more expressions.  Numbers are converted to text.

## Return Value(s)
Returns a string.  If every argument is `NULL`, the result is an empty string.

* * *

## Examples

### Skip NULL values

The `NULL` argument contributes nothing to the result:

```sql
SELECT CONCAT('stackql', '-', NULL, 'labs') AS v;
```

```
|--------------|
|      v       |
|--------------|
| stackql-labs |
|--------------|
```

### Build a label from columns

The following query labels each repository in a GitHub organization with its primary language:

```sql
SELECT name, CONCAT(name, ' (', language, ')') AS label
FROM github.repos.repos
WHERE org = 'stackql-labs';
```

For more information, see [https://www.sqlite.org/lang_corefunc.html#concat](https://www.sqlite.org/lang_corefunc.html#concat)
