Skip to main content

VERSION

Written by Arnaud Lachaume
Updated today

Type: Function

Function: VERSION

Syntax: VERSION(string)

Description: Return the value as-is but apply version-aware sorting based on the x.y.z pattern. Each segment is compared numerically, ensuring that 1.10.0 sorts after 1.9.0.

Only effective if used as a top-level operator.

Sample usage:

  • VERSION(tag_name) returns the tag_name field value unchanged but sorts it as a version number

  • VERSION(CONCAT(field1, ".", field2, ".", field3)) is an example of building a properly sorted version from other fields (e.g. custom fields)

  • CONCAT("v", VERSION(tag_name)) returns the expected value but will NOT make the sorting version-aware since VERSION is not used at the top level.

Did this answer your question?