Re: rw_redis_fdw: SQL Errors when statement is within a function - Mailing list pgsql-general

From Christoph Moench-Tegeder
Subject Re: rw_redis_fdw: SQL Errors when statement is within a function
Date
Msg-id 20181027220550.iazefzdbcxf6phy3@squirrel.exwg.net
Whole thread Raw
In response to Re: rw_redis_fdw: SQL Errors when statement is within a function  (GPT <gptmailinglists@gmail.com>)
List pgsql-general
## GPT (gptmailinglists@gmail.com):

> > And the important thing is: there is no guarantee that the same SQL
> > statement will always execute with the same plan:
> + Yes but there should be guarantee that when the statement is free of
> any syntactic error to be executed successfully and return the
> expected result!!!

It does. Only there's often more than one way to get the correct
result; and PostgreSQL picks the plan which looks "best". And just
for the record: you haven't actually claimed that PostgreSQL returns
the wrong result. The only observation you gave was that PostgreSQL
"sometimes" switches the way to get that result. And to that the
answer is "yes, it does".

> + (By the way, I grub the opportunity. I use DBeaver because Admin III
> does not work properly with pg10 and 11 and BECAUSE Admin4 is a
> NIGHTMARE to install it and make it to work (from the point of a
> simple user!!!))

I wouldn't know about that, there are pre-built packages available
for my systems (which I can install with one command). Anyway, I
use psql for about all things PostgreSQL.

> + What else you need from me to help you find out the source of the problem?

First of all, we'd need to see a problem. As long as the correct data
is returned (and/or written), there is no obvious problem. How PostgreSQL
handles your query is for most cases an implementation detail, which
"normal" users can safely ignore.
The only problem we have seen so far was in rw_redis_fdw (and it has
been fixed) - it could not handle all the plans PostgreSQL could use.

Regards,
Christoph

-- 
Spare Space.


pgsql-general by date:

Previous
From: Alban Hertroys
Date:
Subject: Re: Ltree: set of allowed charcters is limited to [A-Za-z0-9_]. Couldthe dash "-" be included?
Next
From: Christoph Moench-Tegeder
Date:
Subject: Re: rw_redis_fdw: SQL Errors when statement is within a function