Re: plpgsql-function with timestamp

Поиск
Список
Период
Сортировка
Искать
От
Andreas Kretschmer
Тема
Re: plpgsql-function with timestamp
Дата
Msg-id
20060222170954.GA10231@KanotixBox
Ответ на
Список
Дерево обсуждения
Re: plpgsql-function with timestamp "Christian Stalp" <christian.stalp@gmx.de>
Christian Stalp  schrieb:
[ problem ]

Which version?

test=# create table foo (ts timestamp);
CREATE TABLE
test=# insert into foo values ('1999-01-08 04:05:06');
INSERT 0 1
test=# CREATE OR REPLACE FUNCTION neue_auktion (TIMESTAMP) returns text
AS $$ DECLARE my_startzeit    ALIAS FOR $1; BEGIN INSERT INTO foo (ts)
VALUES ( my_startzeit); RETURN 'OK'; END; $$ LANGUAGE plpgsql;
CREATE FUNCTION
test=# SELECT neue_auktion ('1999-01-08 04:05:06');
 neue_auktion
--------------
 OK
(1 row)

test=# select version();
                                                   version
--------------------------------------------------------------------------------------------------------------
 PostgreSQL 8.1.2 on i486-pc-linux-gnu, compiled by GCC cc (GCC) 4.0.3 20060104 (prerelease) (Debian 4.0.2-6)
(1 row)


Btw.: we have a german mailinglist ;-)


HTH, Andreas
-- 
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect.                              (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly."    (unknow)
Kaufbach, Saxony, Germany, Europe.              N 51.05082°, E 13.56889°
В списке pgsql-novice по дате отправления
От: A. Kretschmer
Дата:
Сообщение: Re: drop index
От: Christian Stalp
Дата:
FAQ