All Products
Search
Document Center

Hologres:Version query function HG_VERSION

Last Updated:Dec 09, 2024

You can use the version query function HG_VERSION to obtain the version of your Hologres instance. This topic describes how to use the HG_VERSION function in Hologres.

Limits

The HG_VERSION function is supported only in Hologres V0.10 and later.

HG_VERSION

  • Syntax:

    The HG_VERSION function uses the following syntax:

    HG_VERSION()
  • Return value:

    The information, such as the version of the current Hologres instance, the version of PostgreSQL that is compatible with Hologres, the current operating system, and the compiler, is returned.

  • Example:

    SELECT HG_VERSION();

    The following result is returned. The result shows that the instance version is 0.9.29, the version of PostgreSQL is 11.3, and the current operating system is a Linux 64-bit operating system.

                                                               hg_version                   
    -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
     Hologres 0.9.29 (tag: 0.9.29 build: Release,Skylake,clang), compatible with PostgreSQL 11.3 (Release-build@1b725dxxxx on origin/ralease-0.9.x) on x86_64-pcplinux-gnu, compiled by clang version 8.0.1 (Alibaba 8.0.1-14.alios7),64-bit
    (1 row)