From: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
---|---|
To: | Vincenzo Romano <vincenzo(dot)romano(at)notorand(dot)it> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL General <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Variadic polymorpic functions |
Date: | 2010-01-27 15:52:10 |
Message-ID: | 162867791001270752o29a09277veb2ab437fb1196ce@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
2010/1/27 Vincenzo Romano <vincenzo(dot)romano(at)notorand(dot)it>:
> 2010/1/27 Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>:
>> Hello
>>
>> I add sprintf function. Now I think, we can add new contrib module
>> (string functions) with both function - format and sprintf. These
>> functions are relative different, so they can exists separately.
>> Format is simpler and faster. Sprintf is more powerful but slower.
>>
>> postgres=# select pst.format('now is %', current_time);
>> format
>> ---------------------------
>> now is 16:34:26.203728+01
>> (1 row)
>>
>> postgres=# select pst.sprintf('now is %s', current_time);
>> sprintf
>> --------------------------
>> now is 16:34:45.24919+01
>>
>> Regards
>> Pavel Stehule
>
> Yeah!
>
> But why still on separate schema?
> I'd rather put them all in the public one, so you don't need the "pst." anymore.
> Just like (most of) all other contrib mudules ...
if you like, you can set a search_path
it is cleaner than put all to public schema. I prefer ADA
modul.function notation - it is more readable for me.
Regards
Pavel Stehule
>
From | Date | Subject | |
---|---|---|---|
Next Message | Raymond O'Donnell | 2010-01-27 15:59:33 | Re: syntax error during function call |
Previous Message | Vincenzo Romano | 2010-01-27 15:49:05 | Re: Variadic polymorpic functions |