Re: what does this do - Mailing list pgsql-sql

From Little, Douglas
Subject Re: what does this do
Date
Msg-id 8585BA53443004458E0BAA6134C5A7FB06795979@EGEXCMB01.oww.root.lcl
Whole thread Raw
In response to what does this do  (John <johnf@jfcomputer.com>)
Responses Re: what does this do  (John <johnf@jfcomputer.com>)
List pgsql-sql
First remove the python
select * from jfcs_balancedue(parameter) f(enrolleeid varchar,course_cost decimal, paid_amt decimal)

the jfcs_balancedue is a table function,  f is the alias (with the column alias list/datatype of the columns returned
bythe function). 

Doug


-----Original Message-----
From: pgsql-sql-owner@postgresql.org [mailto:pgsql-sql-owner@postgresql.org] On Behalf Of John
Sent: Thursday, June 10, 2010 4:22 AM
To: pgsql-sql@postgresql.org
Subject: [SQL] what does this do

Hi,
I have a piece of python code that excutes a SQL statement:

apitempCur.execute("select * from jfcs_balancedue('%s') f(enrolleeid varchar,
course_cost decimal, paid_amt decimal)" % (enrollIds,));

The "enrollids" is a list of primary keys and the "jfcs_balancedue" is a user
defined function.  What I don't understand is the "f(enrolleeid
varchar, ...)"   I have no idea what it's for?  Would some kind soul educate
me.

Thanks in advance,
Jhnf

--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-sql


pgsql-sql by date:

Previous
From: Richard Broersma
Date:
Subject: Re: what does this do
Next
From: John
Date:
Subject: Re: what does this do