Ask a Question related to Coldfusion Database Access, Design and Development.
-
JoyRose #1
Need to display query results in specific locations inresults table
:disgust; I need to display the results of a query. The query runs properly.
My problem is having specific results display in specific locations in the
cfoutput table for the query. See attached code. This is what I get: 2005
Program Objectives Table # Objective Q1 Q2 Q3 Q4 (header row)
2 Obj. #2 q2 q3 3 Obj. #3 q2 q4 I need the results to line
up in the table like this: 2005 Program Objectives Table # Objective Q1
Q2 Q3 Q4 (header row) 2 Obj. #2 q2 q3 3 Obj. #3
q2 q4 This is what I get: 2005 Program Objectives Table
# Objective Q1 Q2 Q3 Q4 (header row) 2 Obj. #2 q2 q3
3 Obj. #3 q2 q4 I need the results to line up in the table like this:
2005 Program Objectives Table # Objective Q1 Q2 Q3 Q4 (header
row) 2 Obj. #2 q2 q3 3 Obj. #3 q2 q4
Thanks for any assistance!
This is the query:
<CFQUERY name="q_rpt" datasource="#request.DPCds#"
cachedwithin="#createtimespan(0,0,2,0)#">
SELECT DPCRptr.*, DPCStatRptRptr.*, DPCStatRpt.*, DPCStatRpt.fk_Obj_ID as
Stat_Rpt,
DPCObjText.*, DPCObj.*
FROM DPCRptr, DPCStatRptRptr, DPCStatRpt, DPCObjText, DPCObj
WHERE DPCRptr.Rptr_ID = DPCStatRptRptr.fk_Rptr_ID
and DPCStatRptRptr.fk_StatRpt_ID = DPCStatRpt.StatRpt_ID
and DPCStatRpt.fk_Obj_ID = DPCObjText.fk_Obj_ID
and DPCObjText.fk_Obj_ID = DPCObj.Obj_ID
and DPCObj.fk_ObjType_code = #URL.ObjType#
ORDER BY DPCObjText.fk_Obj_ID, StatRpt_qrtr, created
</CFQUERY>
This is the display code for the query results:
<cfoutput query="q_rpt" group="fk_Obj_ID">
<tr><td>#fk_Obj_ID#</td><td>#ObjText_text#</td>
<cfoutput><td>#StatRpt_qrtr#</td></cfoutput>
</tr>
</cfoutput>
JoyRose Guest
-
HELP! Display query results horizontally
with CFquery, the data is display in the table vertically, is there any way I could display it horizontally? example: #firstname# #firstname#... -
Query results don't display properly in results table.IGNORE PREVIOUS
:disgust; I need to display the results of a query. The query runs properly. My problem is having specific results display in specific locations in... -
Query results don't display properly in results table.
:disgust; I need to display the results of a query. The query runs properly. My problem is having specific results display in specific locations in... -
Display query results in iframe not a table
Hi Problem: I am previewing a PowerPoint slide show in a web page iframe. I would like to be able to link the iframe somehow to a database of... -
How to display a specific value from a table on the form
I have two tables named as Questions and Answers. What I wanted to do is to see the questions on the form while I enter the answers from Answers... -
JoyRose #2
Need to display query results in specific locations inresults table
:disgust; I need to display the results of a query. The query runs properly.
My problem is having specific results display in specific locations in the
cfoutput table for the query. See attached code. Thanks for any assistance!
This is the query:
<CFQUERY name="q_rpt" datasource="#request.DPCds#"
cachedwithin="#createtimespan(0,0,2,0)#">
SELECT DPCRptr.*, DPCStatRptRptr.*, DPCStatRpt.*, DPCStatRpt.fk_Obj_ID as
Stat_Rpt,
DPCObjText.*, DPCObj.*
FROM DPCRptr, DPCStatRptRptr, DPCStatRpt, DPCObjText, DPCObj
WHERE DPCRptr.Rptr_ID = DPCStatRptRptr.fk_Rptr_ID
and DPCStatRptRptr.fk_StatRpt_ID = DPCStatRpt.StatRpt_ID
and DPCStatRpt.fk_Obj_ID = DPCObjText.fk_Obj_ID
and DPCObjText.fk_Obj_ID = DPCObj.Obj_ID
and DPCObj.fk_ObjType_code = #URL.ObjType#
ORDER BY DPCObjText.fk_Obj_ID, StatRpt_qrtr, created
</CFQUERY>
This is the display code for the query results:
<cfoutput query="q_rpt" group="fk_Obj_ID">
<tr><td>#fk_Obj_ID#</td><td>#ObjText_text#</td>
<cfoutput><td>#StatRpt_qrtr#</td></cfoutput>
</tr>
</cfoutput>
This is what I get:
2005 Program Objectives Table
# Objective Q1 Q2 Q3 Q4 (header row)
2 Obj. #2 q2 q3
3 Obj. #3 q2 q4
I need the results to line up in the table like this:
2005 Program Objectives Table
# Objective Q1 Q2 Q3 Q4 (header row)
2 Obj. #2 q2 q3
3 Obj. #3 q2 q4
JoyRose Guest



Reply With Quote

