From: | Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> |
---|---|
To: | Thiemo Kellner <thiemo(at)gelassene-pferde(dot)biz>, "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Empty materialized view |
Date: | 2024-03-24 21:06:19 |
Message-ID: | ed2bdabc-8fb4-4c70-b270-f169fee343ce@aklaver.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On 3/24/24 13:58, Thiemo Kellner wrote:
> Am 24.03.2024 um 21:50 schrieb Adrian Klaver:
>> On 3/24/24 13:36, Thiemo Kellner wrote:
>> It does depending on the order of viewing. Namely if you viewed the
>> 'old' empty MV in the outside session before you dropped/created the
>> 'new' MV and committed the changes.
>
> Something like the viewing session is in a transaction before the
> (re-)creation of the mv?
>
> The view session is on auto commit. (It's sole purpose to query stuff
> and not to have explicitly terminate transactions do to syntax errors
> and so on.)
Autocommit will only affect actions in that session, it will not make
the other sessions actions visible. That depends on the other sessions
committing actions.
See:
https://www.postgresql.org/docs/current/transaction-iso.html
>
> Feeling quite dumb now. But then, there neither is data visible in the
> install session.
>
> insert data into TASK_DEPENDENCY⠒V
> INSERT 0 34
The above says the data was inserted.
> COMMIT
> count
> -------
> 0
Where and when was the count query run?
> (1 row)
>
>
> Thanks for taking care.
--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com
From | Date | Subject | |
---|---|---|---|
Next Message | veem v | 2024-03-24 21:24:27 | Re: Not able to purge partition |
Previous Message | Thiemo Kellner | 2024-03-24 20:58:52 | Re: Empty materialized view |