Re: extend pgbench expressions with functions

Поиск
Список
Период
Сортировка
От Fabien COELHO
Тема Re: extend pgbench expressions with functions
Дата
Msg-id alpine.DEB.2.10.1512211604110.8529@sto
обсуждение исходный текст
Ответ на Re: extend pgbench expressions with functions  (Michael Paquier <michael.paquier@gmail.com>)
Ответы Re: extend pgbench expressions with functions  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-hackers
Hello Michael,

>> I'm not sure whether we are talking about the same thing:
>>  - there a "double" type managed within expressions, but not variables
>>  - there is a double() function, which takes an int and casts to double
>>
>> I understood that you were suggesting to remove all "double" expressions,
>> but now it seems to be just about the double() function.
>
> There is indeed a misunderstanding here: I meant from the start the
> removal of only the "double" function.

Ok. I clearly misunderstood everything...

> It would be nice to keep as user-visible only things that have some 
> meaning.

Why not.

The purpose of some of these functions what to show how the function 
infrastructured extended, as was asked on the thread. The really useful 
ones in the bunch are the arithmetic operators and randoms generators.

> [...] Well, if there were doubles as return results really allocated as 
> doubles in variables having both would make sense. And honestly 
> something like sqrt that returns an integer when allocated in a variable 
> is really surprising.. And as you mentioned upthread there is no real 
> meaning to have doubles variable types that can be allocated.

So you would just like to remove double double(int) and double 
sqrt(double) from the patch, and basically that is all? int int(double)??
debug??? (hmmm, useful debugging a non trivial expression).

-- 
Fabien.



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Paul Ramsey
Дата:
Сообщение: Re: Parallel Aggregate
Следующее
От: Artur Zakirov
Дата:
Сообщение: Re: plpgsql - DECLARE - cannot to use %TYPE or %ROWTYPE for composite types