Determine server version from psql script - Mailing list pgsql-general

From Igor Korot
Subject Determine server version from psql script
Date
Msg-id CA+FnnTyWEsYi=_QTeSXoGXd7Fkd8C7_AnCc5=hho-DZF9_iunQ@mail.gmail.com
Whole thread Raw
Responses Re: Determine server version from psql script
List pgsql-general
Hi, All,
I have a big script that populated the DB for me.

I made it based on the latest available version.

However,  i have version 13 installed on my Linux box and so trying to execute "CREATE OR REPLACE TRIGGER..." will fail.

Is there a way to determine the server version from such a script?

Thank you.

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Nested Stored Procedures - ERROR: invalid transaction termination 2D000
Next
From: Adrian Klaver
Date:
Subject: Re: Determine server version from psql script