CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> ColdFusion

 Drill Downs with counts

Print topic Send  topic

Author Message
cfJeff
Posted: 09/09/2004, 1:24 PM

;-)

I have 2 tables, Questions and Answers. I have a datagrid with a list of all the questions. I want to add a column that counts up the number of "Answers" to that question (related by the QuestionID) and links from the List of Questions to a List of Answers for the specified QuestionID.

I think I have figured out most of it but can't figure out how to do the count of the Answers for each Question.

btw, using cfmx.

Graham Pearson
Posted: 09/10/2004, 3:42 PM

Way I would do it is on the row for the questions, do custom code and
cfquery to get the answers for that question. Then do a cfset for
your fldLabelID = #cfquery.recordcount#
This custom code would go in before show of the label where you want
to display the answers count. This is the same way I did on my Forum
Application written in codecharge and cfml.

9/9/2004 3:24:09 PM
cfJeff <cfJeff@forum.codecharge> wrote in message
<124140bbe9960a0@news.codecharge.com>

> ;-)
>
> I have 2 tables, Questions and Answers. I have a datagrid with a
list of all
> the questions. I want to add a column that counts up the number of
"Answers"
> to that question (related by the QuestionID) and links from the
List of
> Questions to a List of Answers for the specified QuestionID.
>
> I think I have figured out most of it but can't figure out how to
do the count
> of the Answers for each Question.
>
> btw, using cfmx.
>
>
> ---------------------------------------
> Sent from YesSoftware forum
> http://forums.codecharge.com/
---
Graham Pearson, System Administrator / Web Developer
Northern Indiana Educational Services Center
56535 Magnetic Drive, Mishawaka IN 46544
http://www.niesc.k12.in.us
Graham Pearson
Posted: 07/10/2005, 6:58 PM

Use Custom Code to create a query to count(QuestionID) where something =
QuestionID then set the control name to the query.recordcount



cfJeff wrote:
> ;-)
>
> I have 2 tables, Questions and Answers. I have a datagrid with a list of all
> the questions. I want to add a column that counts up the number of "Answers"
> to that question (related by the QuestionID) and links from the List of
> Questions to a List of Answers for the specified QuestionID.
>
> I think I have figured out most of it but can't figure out how to do the count
> of the Answers for each Question.
>
> btw, using cfmx.
>
>
> ---------------------------------------
> Sent from YesSoftware forum
> http://forums.codecharge.com/
>

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Internet Database

Visually create Web enabled database applications in minutes.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.