Hi
This is what I'm trying to do:
Select Name
From tblDevelopments
Where DevelopmentID = Max(
SELECT tblPFTopics.DevelopmentID, Count(*) as TotalDev
FROM tblPFEntries, tblPFTopics, tblPFThreads
WHERE tblPFTopics.TopicID =tblPFThreads.TopicID AND tblPFThreads.ThreadID=tblPFEntries.ThreadID
Group By tblPFTopics.DevelopmentID)
But as you probably already know, I can't use MAX in the WHERE clause.
What is the best way to go about this?
Many thanks
Shaun
This is what I'm trying to do:
Select Name
From tblDevelopments
Where DevelopmentID = Max(
SELECT tblPFTopics.DevelopmentID, Count(*) as TotalDev
FROM tblPFEntries, tblPFTopics, tblPFThreads
WHERE tblPFTopics.TopicID =tblPFThreads.TopicID AND tblPFThreads.ThreadID=tblPFEntries.ThreadID
Group By tblPFTopics.DevelopmentID)
But as you probably already know, I can't use MAX in the WHERE clause.
What is the best way to go about this?
Many thanks
Shaun