On Thu, Dec 15, 2005 at 08:31:09PM -0500, Michael Avila wrote:
> What I want to do is find the latest status for each member. Actually I want
> to find all those with an status of "A". But it must be the current (latest)
> status. How do I find the most current date for each member in a pile of
> m
I have a table which keeps track of the status of members. In the table is
member_id int(8)
status_code char(1)
status_date date
KEY member_id (member_id,status_code,status_date)
Each member can have multiple records because a record is added each time
the status changes but the old record i
Thanks, Tom (also Keith Worthington and Bricklen Anderson). That works.
~ Ken
> -Original Message-
> From: Tom Lane [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, December 14, 2005 1:15 PM
> To: Ken Winter
> Cc: PostgreSQL pg-sql list
> Subject: Re: [SQL] Defaulting a column to 'now'
>
>
grupos wrote:
Hi Richard,
Thanks for your promptly answer. I don't have experience returning
refcursor but my choice would be it.
>
I read the documentation but I didn't find any example with my necessity...
http://www.postgresql.org/docs/8.1/static/plpgsql-cursors.html#PLPGSQL-CURSOR-USING
Hi Richard,
Thanks for your promptly answer. I don't have experience returning
refcursor but my choice would be it.
I read the documentation but I didn't find any example with my necessity...
Could you give me a small example on the same "basis" that I want?
Thanks,
Rodrigo Carvalhaes
Richa
grupos wrote:
Hi !
I am making one plpgsql function and I need to return of setof data
using a cursor.
The problem is that my function is returning only the first row and
column of the query. This query have more than 80 columns and 1.000
rows. Enyone have any tip to give me?
Yes - decide
Gianluca Riccardi wrote:
[cut]
solved,
i used a function giving as result the wanted value from table2.column1
in a UPDATE table1 SET column4=(my_personal_func()) WHERE 'cirteria on
table1.column2 table2.column2' ;
sorry for making you wasting your time
Gianluca Riccardi
---
Hi !
I am making one plpgsql function and I need to return of setof data
using a cursor.
The problem is that my function is returning only the first row and
column of the query. This query have more than 80 columns and 1.000
rows. Enyone have any tip to give me?
Here the fuction...
CREATE
sorry for posting a new opening 'thread', but my subscribing to the ml
is later than a post with the subject 'APPEND INTO?' dated Thu, 01 Dec
2005 10:32:08 -0500 so i can't make reply to that.
follows a copy of that post
Mark Fenbers writes:
I want to SELECT INTO mytable WHERE (criteria are m