HG_VERSION

Updated at:

HG_VERSION() returns the version information for the current Hologres instance, including the instance version, compatible PostgreSQL version, operating system, and compiler.

HG_VERSION is supported in Hologres V0.10 and later.

Syntax

HG_VERSION()

Return value

The function returns a single text string containing the following fields:

FieldDescriptionExample value
Hologres versionVersion of the Hologres instance0.9.29
PostgreSQL versionPostgreSQL version that Hologres is compatible with11.3
Operating systemOS type and CPU architecturex86_64-pcplinux-gnu, 64-bit
CompilerCompiler name and versionclang version 8.0.1

Example

SELECT HG_VERSION();

Output:

                                                           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)

In this output, the instance version is 0.9.29, the compatible PostgreSQL version is 11.3, and the operating system is x86_64-pcplinux-gnu (Linux 64-bit).