CONTAINS (string)

Function CONTAINS is also found in the following categories: Array functions.

Syntax

CONTAINS( string, substring )

Description

Returns TRUE if string contains substring. For case-insensitive searches, see ICONTAINS.

Argument types:

  • stringBoolean | Date | Datetime | Fractional number | Geopoint | Geopolygon | Integer | String | UUID
  • substringString

Return type: Boolean

Examples

CONTAINS("RU0891923", "RU") = TRUE
CONTAINS("Lorem ipsum", "abc") = FALSE

Data source support

ClickHouse 19.13, Microsoft SQL Server 2017 (14.0), MySQL 5.6, PostgreSQL 9.3.

Previous