On Mon, Jun 8, 2009 at 2:18 PM, Jeff Davis wrote:
> On Sat, 2009-06-06 at 15:03 -0400, Merlin Moncure wrote:
>> sql functions are pretty inflexible...even with recent even with
>> recent advancements like varargs and default parameters they are
>> designed to do a very particular thing...and insert
On Sat, 2009-06-06 at 15:03 -0400, Merlin Moncure wrote:
> sql functions are pretty inflexible...even with recent even with
> recent advancements like varargs and default parameters they are
> designed to do a very particular thing...and insert/update tend to be
> fairly generic in how they operate
On Fri, Jun 5, 2009 at 1:58 PM, Jean Hoderd wrote:
>
> Hi,
>
>> So I don't recommend you try to do this. What is the actual problem
>> you are trying to solve? Why do you want the client library to be
>> concerned with attnotnull at all?
>
> In general the client library needs to check attnotnull
On Fri, 2009-06-05 at 10:58 -0700, Jean Hoderd wrote:
> The above example was absurdly simple, but in the real world the query
> is complex enough that instead of being just a SELECT is actually the
> return of a PL/PGSQL function. I just want a way to tell the client
> which fields from the retur
Hi,
> So I don't recommend you try to do this. What is the actual problem
> you are trying to solve? Why do you want the client library to be
> concerned with attnotnull at all?
In general the client library needs to check attnotnull to make sure
that the client is not making a type mistake.
Jean Hoderd writes:
> I have tried the following, but it's not accepted:
> create type result as (name text not null, age int4 not null);
Frankly, the notion that a "not null" condition might be associated with
a SQL data type is simply a bad idea. The SQL committee let this happen
for domains i
Dear list,
Here's the situation: I want to create a functional API to a Postgresql
database, in such a way that instead of issuing raw SQL commands (SELECT,
INSERT, etc), the client will only invoke functions from this API.
For example, to get all people in the database, the client will invoke
f