help with complex query
| From: | Noah Spitzer-Williams | Date: | Mon, 12 Nov 2001 00:51:05 +0000 |
| Subject: | help with complex query | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-14237@lists.php.net to get a copy of this message | ||
hey guys, ok i have a table that looks somethign like this:
1 | js | 1.3 | 10
1 | js | 1.3 | 5
1 | js | 1.2 | 3
2 | browser | ie5 | 17
lets say the first column refers to a web site's id and the two middle
columns are stats about the site. the last column is how many times that
stat occured. for example, site 2 had 17 visitors using the ie5 browser.
what i want to do is make a 'global stats' page that combines all of the
stats. it would read:
js | 1.3 | 15
js | 1.2 | 3
browser | ie5 | 17
noticed how it combined the two js 1.3 columns
i've tried grouping and many other things i just cant figure out how to do
it.
any help is appreciated!
- Noah
www.trademytraffic.com