Skip site navigation (1) Skip section navigation (2)

Re: Proposal: new function array_init

From: "Pavel Stehule" <pavel(dot)stehule(at)gmail(dot)com>
To: Decibel! <decibel(at)decibel(dot)org>
Cc: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Proposal: new function array_init
Date: 2008-06-04 12:57:38
Message-ID: 162867790806040557k54f910e5ya632fdb244ab490f@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
2008/6/4 Decibel! <decibel(at)decibel(dot)org>:
> On Jun 2, 2008, at 11:46 AM, Tom Lane wrote:
>>
>> * Should the fill value be the first parameter instead of the last?
>
>
> +1. The other way just seems weird, at least to me.

can you write reason?

I put fill value on end, because it is like default value:

array_set(array[2,2]);
array_set(array[2,2], 0);
array_set(array[2,2],array[1,1]);
array_set(array[2,2],array[1,1], 0); - and it's analogy to memset fce
etc set(where, value);

Pavel

> --
> Decibel!, aka Jim C. Nasby, Database Architect  decibel(at)decibel(dot)org
> Give your computer some brain candy! www.distributed.net Team #1828
>
>
>

In response to

Responses

pgsql-hackers by date

Next:From: Decibel!Date: 2008-06-04 13:00:49
Subject: Re: Overhauling GUCS
Previous:From: Decibel!Date: 2008-06-04 12:44:53
Subject: Re: Proposal: new function array_init

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group