pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael.paquier@gmail.com>
To: Raymond O'Donnell <rod@iol.ie>
Cc: hmidi slim <hmidi.slim2@gmail.com>
Cc: pgsql-general@postgresql.org
Subject: Re: Notify client when a table was full
Date: Sun, 21 Jan 2018 21:27:18 +0900
Message-ID: <20180121122718.GH1311@paquier.xyz> (raw)
In-Reply-To: <2f4c0da8-9ae8-4262-667e-538d5f6f67ec@iol.ie>
References: <CAMsqVxsC0KNNra5t4Sd_A119U=MAXQqmZ7BmQpk0LimK=-qC7A@mail.gmail.com>
	<2f4c0da8-9ae8-4262-667e-538d5f6f67ec@iol.ie>

On Fri, Jan 19, 2018 at 03:40:01PM +0000, Raymond O'Donnell wrote:
> On 19/01/18 15:34, hmidi slim wrote:
>> Hi,
>> I'm looking for a function in postgresql which notify the client if a
>> table was full or not.So I found the function Notify
>> https://www.postgresql.org/docs/9.0/static/sql-notify.html.
>> This function send a notification when a new action was done to the
>> table. Is there a way to send a notification only  when the table was
>> full and no future actions (insertion of new rows for examples) will be
>> done. I was connected to an external api and saving the data received
>> from it to a postgres database and I want to be notified when the table
>> was full and no rows will be inserted. Does it realizable or Should I
>> create a trigger and listens for every insertion and notify the client?
> 
> How do you define "full"?

There could be two definitions here:
1) A table contains more data than a customly-defined amount of data
on-disk.
2) The partition where the table data is located runs out of disk
space.
--
Michael

Attachments:

  signature.asc (application/pgp-signature, 832B) download

view thread (11+ messages)  latest in thread

Message-ID: <20180121122718.GH1311@paquier.xyz>
Permalink:  ../20180121122718.GH1311@paquier.xyz/
Also on:    postgresql.org/message-id/20180121122718.GH1311@paquier.xyz

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: michael.paquier@gmail.com, rod@iol.ie, hmidi.slim2@gmail.com
  Subject: Re: Notify client when a table was full
  In-Reply-To: <20180121122718.GH1311@paquier.xyz>
  References: <CAMsqVxsC0KNNra5t4Sd_A119U=MAXQqmZ7BmQpk0LimK=-qC7A@mail.gmail.com> <2f4c0da8-9ae8-4262-667e-538d5f6f67ec@iol.ie> <20180121122718.GH1311@paquier.xyz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox