> > Now when creating a function you can do:
> >CREATE FUNCTION foo(text) RETURNS setof RECORD ...
> >
> > And when using it you can do, e.g.:
> >SELECT * from foo(sqlstmt) AS (f1 int, f2 text, f3 timestamp)
>
> Why is there the requirement to declare the type at SELECT
> time at all?
Christopher Kings-Lynne wrote:
> Why is there the requirement to declare the type at SELECT time at all? Why
> not just take what you get when you run the function?
The column names and types are determined in the parser, and used in the
planner, optimizer, and executor. I'm not sure how the ba
> I get an error with current:
>
> test=# RESET SESSION AUTHORIZATION;
> ERROR: parser: parse error at or near "AUTHORIZATION"
It tured out that outdated gram.c file caused the problem after doing
cvs up (I don't know why). Anyway sorry for the false alarm.
--
Tatsuo Ishii
> We are in the process of moving to Postgres from Oracle. We were using
> "savepoint xyz" and "rollback to savepoint xyz" with Oracle. Or these
> supported by Postgres?, if so what are the equivalent queries in postgres
> for the same.
No, they're not supported in any released version. Postgres
I get an error with current:
test=# RESET SESSION AUTHORIZATION;
ERROR: parser: parse error at or near "AUTHORIZATION"
--
Tatsuo Ishii
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.org
> 3. Modify FROM clause grammer to accept something like:
> SELECT * FROM my_func() AS mtf(colname1 type1, colname2 type1, ...)
> where mtf is the table alias, colname1, etc are the column names, and
> type1, etc are the column types.
...
> Now when creating a function you can do:
>CREAT
Hi,
We are in the process of moving to Postgres from Oracle. We were using
"savepoint xyz" and "rollback to savepoint xyz" with Oracle. Or these
supported by Postgres?, if so what are the equivalent queries in postgres
for the same.
Thanks
Yuva
Sr. Java Developer
www.ebates.com
I see this using the latest CVS code:
$ make installcheck
[ all tests pass ]
$ pg_dump regression > /tmp/regression.dump
$ psql template1
template1=# drop database regression;
DROP DATABASE
template1=# create database regression;
CREATE DATABASE
template1=# \c regression
You are now connected to
On Wed, Jul 24, 2002 at 04:23:56PM -0400, Tom Lane wrote:
> [EMAIL PROTECTED] (Neil Conway) writes:
> > This behavior doesn't look right:
>
> It's not, but I believe the correct point of view is that the input
> data is defective and should be rejected. See past discussions
> leading up to the T
I thought that it might involve more than met the eye. I'm resisting the
"view" approach since, like my bad kludge, it locks down the table
definition and as a result doesn't provide a very effective synonym
mechanism.
I'm looking into the commands/view.c as a basis for introducing the
concep
[EMAIL PROTECTED] (Neil Conway) writes:
> This behavior doesn't look right:
It's not, but I believe the correct point of view is that the input
data is defective and should be rejected. See past discussions
leading up to the TODO item that mentions rejecting COPY input rows
with the wrong number
This behavior doesn't look right:
nconway=# create table foo (a int default 50, b int default 100);
CREATE TABLE
nconway=# copy foo from stdin;
Enter data to be copied followed by a newline.
End with a backslash and a period on a line by itself.
>>
>> \.
nconway=# select * from foo;
a | b
---+
Hello all,
There is a limitation currently with Table Functions in that the return
tuple type must be known in advance, i.e. you need a pre-defined scalar
or composite type to use as the function's declared return type.
This doesn't work well for the type of function that needs to return
diff
Marc Lavergne <[EMAIL PROTECTED]> writes:
> I have a need for relation synonyms in PostgreSQL. I don't see it in
> 7.2.1 but the catalog seems to be able to support it more or less.
> Here's what I intend to do:
> 1) Create a duplicate record in pg_class for the base table information
> but wi
Tatsuo Ishii <[EMAIL PROTECTED]> writes:
> Once I thought of a conversion lookup cache, but it seems impossible
> to implent it since the cache needs to be invalidated when the schema
> search path is changed.
On the contrary, that seems very easy to do. There is a hook to let you
get control wh
> This sounds like a really bad idea to me. A syscache based on a partial
> index is almost certainly not going to work.
>
> Before we invest in a lot of effort making bootstrap, syscache, and who
> knows what else support partial indexes, I want to see a very clear
> explanation why we must do
On Wed, 2002-07-24 at 02:22, Marc Lavergne wrote:
> I have a need for relation synonyms in PostgreSQL. I don't see it in
> 7.2.1 but the catalog seems to be able to support it more or less.
>
> Here's what I intend to do:
>
> 1) Create a duplicate record in pg_class for the base table informati
Hello together,
i've seen that every process created in Postgres will
eave some memory unreleased and the garbage
collector of the OS has to free this memory.
Is there any special reason for this or is it just
something that has to be solved?
Ulrich Neumann
--
Bruce Momjian <[EMAIL PROTECTED]> writes:
> In private email with Tatsuo, I learned it is for the new loadable
> encoding patch, and he wants to use the index from the syscache. The
> reason for the partial index is because the index itself would not be
> unique, but a partial index would be uniq
On Tuesday 23 July 2002 22:28, Joe Conway wrote:
> Darko Prenosil wrote:
> > Before about 3 months I send to You pl/pgSql wrapper functions for libpq.
> > We agreed then, that merging it with dblink would be a good idea.
> > Meanwhile i used dblink and those functions and wrote some kind of
> > r
20 matches
Mail list logo