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

[View as HTML](https://www.tigergraph.com/docs/gsql-ref/4.1/ddl-and-loading/functions/token_where/token_len)

# token_len()

Returns the length of a string. This is a token function for the `WHERE` clause of a `LOAD` statement only. It cannot be used in a destination clause.

## Syntax

`token_len( token )`

## Return value

`INT`. The length of the input token.

## Example

token_len("gsql") -> 4
