---
title: "gsql_regex_match()"
component: "gsql-ref"
version: "3.10"
module: "ddl-and-loading"
html_url: "/gsql-ref/3.10/ddl-and-loading/functions/token/gsql_regex_match"
canonical_url: "https://www.tigergraph.com/docs/gsql-ref/3.10/ddl-and-loading/functions/token/gsql_regex_match"
markdown_url: "https://www.tigergraph.com/docs/gsql-ref/3.10/ddl-and-loading/functions/token/gsql_regex_match.md"
---

[View as HTML](https://www.tigergraph.com/docs/gsql-ref/3.10/ddl-and-loading/functions/token/gsql_regex_match)

# gsql_regex_match()

Returns true if the given string token matches the given regex token and false otherwise.

## Syntax

`gsql_regex_match(str, regex)`

## Parameters

str

The string to match against the regex.

regex

The regex used to match the string.

## Return type

`BOOL`

## Example

gsql_regex_match("subject","(sub)(.*)") -> TRUE
