Thanks for the tip, Jayadevan!
Looks like your suggestion can help med with this.
I’m getting all the info I need from this view.

Cheers,
Bjørn


From: Jayadevan M <maymala.jayade...@gmail.com>
Date: Tuesday, 19 January 2021 at 12:33
To: "Myklebust, Bjørn Magnar" <bjorn.mykleb...@skatteetaten.no>
Cc: "pgsql-gene...@postgresql.org" <pgsql-gene...@postgresql.org>
Subject: Re: How to check if a materialised view is being updated?



So I’m looking for a way to identify if the refresh process is finished or if 
it’s still running  - preferably without having to wait for timeout by querying 
a locked materialized view.  But by e.g. using the system tables or otherwise.

Can anybody suggest some pointers on how to do this?

Maybe pg_stat_activity will have the refresh query?

Regards,
Jayadevan

________________________________
Denne e-posten og eventuelle vedlegg er beregnet utelukkende for den 
institusjon eller person den er rettet til og kan være belagt med lovbestemt 
taushetsplikt. Dersom e-posten er feilsendt, vennligst slett den og kontakt 
Skatteetaten.
The contents of this email message and any attachments are intended solely for 
the addressee(s) and may contain confidential information and may be legally 
protected from disclosure. If you are not the intended recipient of this 
message, please immediately delete the message and alert the Norwegian Tax 
Administration.

Reply via email to