> I am trying to use INNER JOIN for my query and have > additional conditions, what is the right way to add them? > When I run the code below, I get the error shown. How do I > get this to work? > > SELECT v.Party, SUM(v.Votes), s.ConstituencyNo > ,c.ConstituencyName, c.RegionCode FROM VoteResults v INNER > JOIN PollingStation s > ON v.AgentPhoneNo = s.AgentPhoneNo > WHERE v.ResultCategory = > 'L' AND v.Party = 'NPP' > INNER JOIN Constituency c > ON c.ConstituencyNo = s.ConstituencyNo > GROUP BY v.Party, s.ConstituencyNo, > ,c.ConstituencyName, c.RegionCode
SELECT ... FROM VoteResults v INNER JOIN PollingStation s ON v.AgentPhoneNo = s.AgentPhoneNo INNER JOIN Constituency c ON c.ConstituencyNo = s.ConstituencyNo WHERE v.ResultCategory = 'L' AND v.Party = 'NPP' GROUP BY v.Party, ... ORDER BY ... Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Training: Adobe/Google/Paperthin Certified Partners http://training.figleaf.com/ WebManiacs 2008: the ultimate conference for CF/Flex/AIR developers! http://www.webmaniacsconference.com/ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:300389 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4