Welcome Guest, Not a member yet? Register   Sign In
Multiple joins and multiple counts
#3

[eluser]Phil Sturgeon[/eluser]
Your sub query approach will work out better. Before you probably had problems as each time you are joining tables together you are saying "all the fields should be returned together". This means that the count will count empty strings all over the place, and give you identical or screwy results.

A sub query for each count is usual best practice.


Messages In This Thread
Multiple joins and multiple counts - by El Forum - 11-19-2008, 04:32 AM
Multiple joins and multiple counts - by El Forum - 11-19-2008, 05:28 AM
Multiple joins and multiple counts - by El Forum - 11-19-2008, 06:03 AM
Multiple joins and multiple counts - by El Forum - 11-19-2008, 06:04 AM



Theme © iAndrew 2016 - Forum software by © MyBB