I think I'm getting closer. This code below works but I don't know how to total
each fdd_name.
For Example:
ACME FD1 (38)
ACME FD2 (30)
ACME FD3 (20)
<cfquery name="Zip" datasource="#dsn#">
SELECT a.zipcode, f.fdd_zip, f.fdd_name, a.IsPublished, a.IsActive, f.fdd_state
FROM articles a, fddirectory f
WHERE a.zipcode = f.fdd_zip
AND f.fdd_state = <cfqueryparam cfsqltype="cf_sql_varchar" value="MD">
GROUP BY f.fdd_name
</cfquery>
<cfoutput query="Zip">
#fdd_name# (Add Total Here)<br>
</cfoutput>
Thanks,
Barry
>You just need a JOIN and GROUP BY clause. Check out the
>subquery-to-join docs on MySQL's site. They have examples of how to do
>exactly what you want.
>
>cheers,
>barneyb
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know
on the House of Fusion mailing lists
Archive:
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330756
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4