Re: [GENERAL] Help me with this tricky join

2010-03-21 Thread A. Kretschmer
In response to Jay : Thanks! But, since the master can contain many users (user2, user3, and so on) I suppose this won't be a proper solution? Sorry if I was a bit unclear in my description. I.e., the master is of the form: user_id date User1 20010101 User1 2101 User1 19990101

Re: [GENERAL] Help me with this tricky join

2010-03-20 Thread Andreas Kretschmer
Jay josip.2...@gmail.com wrote: Hi, I'm somewhat new to SQL so I need a bit of help with this problem. So I have 2 tables: selection and master, both have two columns in each: user_id and date. The selection contains one row for each user_id and depicts _one_ date value for each user.

Re: [GENERAL] Help me with this tricky join

2010-03-20 Thread Jay
Thanks! But, since the master can contain many users (user2, user3, and so on) I suppose this won't be a proper solution? Sorry if I was a bit unclear in my description. I.e., the master is of the form: user_id date User1 20010101 User1 2101 User1 19990101 User1 19970101 User2 ... ... Btw,

[GENERAL] Help me with this tricky join

2010-03-19 Thread Jay
Hi, I'm somewhat new to SQL so I need a bit of help with this problem. So I have 2 tables: selection and master, both have two columns in each: user_id and date. The selection contains one row for each user_id and depicts _one_ date value for each user. The master contains all date changes for

Re: [GENERAL] Help me with this tricky join

2010-03-19 Thread Jay
CORRECTION: The original selection should be: User1 2101 NOT User1 19990101 -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general