# String

A UTF-8 character string type.

## [](#_in_expressions)In expressions

Strings can be concatenated using the `+` operator.

```typeql
"Hello," + " world!" == "Hello, world!"
```

## [](#_defining_a_string_valued_attribute)Defining a string valued attribute

```typeql
#!test[schema]
define
  attribute name value string;
```

## [](#_inserting_a_string_valued_attribute)Inserting a string valued attribute

```typeql
#!test[write]
insert
  $_ isa name "John";
```

## [](#_unicode_support)Unicode support

TypeDB supports unicode characters in strings, as well as providing a syntax for escaping unicode characters. The escape is `\u{<code>}` where `<code>` is the hex-encoded character-code.

```typeql
#!test[read, count=1]
match
  let $x = "A\u{42}C \u{130ED}\u{13153}";
  let $y = "ABC 𓃭𓅓";
  $x == $y;
```

[Decimal](../decimal/index.md) [Date](../date/index.md)

[Edit on GitHub](https://github.com/typedb/typedb-docs/edit/3.x-development/typeql-reference/modules/ROOT/pages/values/string.adoc) Edit this page on GitHub.