-
Probs with count()
the "Teller" count has numbers in it that are the same as "aantal" but in other sizes.
Once "Teller" has more identical numbers then "aantal" it starts counting totally wrong!!
here is my code, i think there is some fault in there, maybe someone of you knows better then me
SELECT
ww_forum_teller.none, count(onderwerpID) as teller,
ww_forum_nieuws_antwoorden.subjectID,
count(subjectID) as aantal,
ww_forum_nieuws_onderwerpen.onderwerp,
forumid,
ww_forum_nieuws_onderwerpen.gebruikersnaam,
ww_forum_nieuws_onderwerpen.nummer
FROM
(ww_forum_nieuws_antwoorden right outer join ww_forum_nieuws_onderwerpen
on
ww_forum_nieuws_antwoorden.subjectid=ww_forum_nieu ws_onderwerpen.nummer)
left outer join ww_forum_teller
on
ww_forum_nieuws_antwoorden.subjectid = ww_forum_teller.onderwerpID
WHERE
forumid = 'param1'group by nummer
ORDER BY nummer desc
-
I did not realy understand your question can you tell me how is your table setup and what exactly you want to do (and why)
Thank you
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|