Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

query results display twice - why???

Status
Not open for further replies.

MtnGirl

Programmer
Sep 20, 2001
8
US
This seems like it should be fairly simple. I queried a database and want to display the results in a table but what I'm getting is the results of the query totally unformatted and comma delimited above the table on the web page. Then the table displays correctly underneath. Why are the results of the query displaying twice? I'm really new to this but I thought you would only see the results of your query if you used CFOUTPUT tags. So why is it showing up outside of these tags? I'd appreciate any help. Seems like it should be something simple. My code is below.

Thanks so much!

<CFSET temp.begindate = &quot;#form.month#/#form.day#/#form.year#&quot;>
<CFQUERY NAME=&quot;resbydates&quot; DATASOURCE=&quot;newaen1&quot;>
SELECT MEMNAME, ResumeID, rDate, rEmpPrefTitle, memid
FROM resumeview
WHERE rDate = #createodbcdate(temp.BeginDate)#
</CFQUERY>


<!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0 Transitional//EN&quot;>

<html>
<head>
<title>Resumes By Date</title>
</head>

<body>
<table border=&quot;0&quot; cellpadding=&quot;3&quot; cellspacing=&quot;0&quot; width=&quot;600&quot;>
<tr>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Job Reference Number</b></font>
</td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Job Listing ID</b></font>
</td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Job Title</b></font>
</td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Applicant ID</b></font>
</td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Applicant Name</b></font>
</td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif><b>Resume ID</b></font>
</td>
</tr>


<CFOUTPUT QUERY=&quot;resbydates&quot;>
<tr>
<td width=100> </td>
<td width=100> </td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#rEmpPrefTitle#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#memid#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#MEMNAME#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#ResumeID#</font></td>
<p>#rEmpPrefTitle#, #memid#, #MEMNAME#, #ResumeID#</p>
</tr>
</CFOUTPUT>


</table>
</body>
</html>
 
<CFOUTPUT QUERY=&quot;resbydates&quot;>
<tr>
<td width=100> </td>
<td width=100> </td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#rEmpPrefTitle#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#memid#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#MEMNAME#</font></td>
<td width=100><font size=&quot;2&quot; face= Arial, Verdana, Helvetica, sans-serif>#ResumeID#</font></td>
<p>#rEmpPrefTitle#, #memid#, #MEMNAME#, #ResumeID#</p>
</tr>
</CFOUTPUT>

This is not in a cell therefore showing at the top of the table
DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
Thank you! I knew it had to be something simple. Guess I've been at the computer too long today.

Thanks again!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top