- Original Message -
From: "OKi98" <[EMAIL PROTECTED]>
To:
Sent: Friday, January 05, 2007 1:19 PM
Subject: Re: [PHP-DB] Multiple Count's in one Select.
Ed wrote:
SELECT DISTINCT u.*, t.*, (SELECT COUNT(jobtype) FROM taskinput WHERE
t.user_id = u.user_id
Ed wrote:
SELECT DISTINCT u.*, t.*, (SELECT COUNT(jobtype) FROM taskinput WHERE
t.user_id = u.user_id ) AS 'COUNT', (SELECT COUNT(jobtype) FROM
taskinput WHERE t.user_id = u.user_id AND t.jobtype = 'Navision') AS
'Navision', (SELECT COUNT(jobtype) FROM taskinput WHERE t.user_id =
u.user_id A
- Original Message -
From: "Chris" <[EMAIL PROTECTED]>
To: "Ed" <[EMAIL PROTECTED]>
Cc:
Sent: Friday, January 05, 2007 5:23 AM
Subject: Re: [PHP-DB] Multiple Count's in one Select.
[ please don't top-post, makes it hard to follow ]
Ed wro
abase dump ? Probably best to
send off list if that's ok.
You have a complicated query so it'll be easier seeing the table
definitions and having some data to work with ;)
- Original Message - From: "Chris" <[EMAIL PROTECTED]>
To: "Ed" <
get any kind of result where adding the extra WHERE
t.user_id = u.user_id AND t.jobtype = 'Tickets'
It's got me stumped, but then i've not slept in nearly 24 hours.
Thanks for your help so far :-)
- Original Message -
From: "Chris" <[EMAIL PROTECTED]>
To
Ed wrote:
Hi,
I've been expermenting with displaying stats for our intranet and I'm
looking at making it more robust so it can display stats better.
I've come up with the most ugly! long winded SQL statement You could
imagine.
SELECT DISTINCT u.*, t.*, (SELECT COUNT(jobtype) FROM taskinput
Hi,
I've been expermenting with displaying stats for our intranet and I'm
looking at making it more robust so it can display stats better.
I've come up with the most ugly! long winded SQL statement You could
imagine.
SELECT DISTINCT u.*, t.*, (SELECT COUNT(jobtype) FROM taskinput WHERE
t.u