Re: SQL-help needed

2004-02-19 Thread Michael Stassen
Carl Schéle, IT, Posten wrote: Hi! I got a table, champions, looking like this: idclass winner_1 winner_2 year - 0 hd carl mattias 1957 1

RE: SQL-help needed

2004-02-19 Thread Ligaya Turmelle
: Carl Schéle, IT, Posten [mailto:[EMAIL PROTECTED] Sent: Thursday, February 19, 2004 6:50 PM To: [EMAIL PROTECTED] Subject: SQL-help needed Hi! I got a table, champions, looking like this: idclass winner_1

SQL-help needed

2004-02-19 Thread "Carl Schéle, IT, Posten"
Hi! I got a table, champions, looking like this: idclass winner_1 winner_2 year - 0 hd carl mattias 1957 1 hs daniel

RE: SQL Help Needed

2002-05-23 Thread Roger Baklund
* Dave > Thanks for your responses but it's not that much help I need with > my SQL ;-) > > None of the 3 suggestions work. > > Please look at the examples I gave. I need *all* UserIDs regardless of > whether they have a record in History that matches both UserID and WeekID. ...and that is what

Re: SQL Help Needed

2002-05-23 Thread Dave
only exist for WeekID = 2, other for 1 and 2 and so on. Cheers Dave - Original Message - From: "Roger Baklund" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Cc: "Dave" <[EMAIL PROTECTED]> Sent: Thursday, May 23, 2002 6:21 PM Subject: RE: SQL

RE: SQL Help Needed

2002-05-23 Thread Gurhan Ozen
SELECT UserID, WeekID, SUM(Points) AS WeeklyPoints FROM History GROUP BY WeekID; Gurhan -Original Message- From: Dave [mailto:[EMAIL PROTECTED]] Sent: Thursday, May 23, 2002 9:37 AM To: [EMAIL PROTECTED] Subject: SQL Help Needed I have 2 tables Users (UserID) History (UserID

RE: SQL Help Needed

2002-05-23 Thread Roger Baklund
* Dave > I have 2 tables > > Users (UserID) > > History (UserID, WeekID, Points) > > When a User record is created a record is inserted into History with the > current WeekID, so for example data could be : > > Users > > > > > > > History > -- > - 1 - 10 >

Re: SQL Help Needed

2002-05-23 Thread Nick Stuart
Ok this should be easy so I'm prolly going to screw it up, but here goes =D Your query should be: SELECT UserID, SUM(points) FROM History WHERE WeekID = 'whatever' GROUP BY UserIdI think that should do it. Someone yell if its wrong though. -Nick > I have 2 tables > > Users (UserID) > > History

SQL Help Needed

2002-05-23 Thread Dave
I have 2 tables Users (UserID) History (UserID, WeekID, Points) When a User record is created a record is inserted into History with the current WeekID, so for example data could be : Users History -- - 1 - 10 - 1 - 20 - 1 - 30 - 2 - 40