Robm_01
July 3rd, 2005, 11:38 AM
Hi
I have a strange problem that has developed recently and wondered if someone could help me here please as I'm completely foxed with this one.
For over a year now I have had a couple of pages that perform filtered category searches that have worked perfectly well all this time and all of a sudden I get a "no records returned" displayed.
I have tested the pages on my local machine it all works fine. However, when I try the searches online it fails every time.
I have tried deleting all the files and re-uploading the entire site, I have created cut down versions without all the bells and whistles all works great locally but not on line.
The pages in question are:
http://www.imagerealm.co.uk/search_f1.asp
http://www.imagerealm.co.uk/search_gen.asp
click on a category on the lower left dropdown and it will display the number of images found and also display the thumbnails. (this is the bit that no longer works.)
Here is an example of a page that does what it should, although the query is slightly different. http://www.imagerealm.co.uk/search_cat.asp?ID=7 It’s a very similar display.
I think the Query is being bounced or something at the ISP.
This code works fine and does retrieve the results using a straight select all
"SELECT * FROM Photo"
When I use the following query it fails to retrieve the results but is fine locally.
"SELECT DISTINCT Photo.PDesc, Photographer.Fullname AS Expr1, Photo.PhotoID, Photo.Date, Photo.Size, Photo.Filename, Photographer.photogID, Photographer.GalleryLink FROM Photographer AS Photographer_1, (tCat INNER JOIN tSCat ON tCat.CatID = tSCat.CatID) INNER JOIN ((Photo INNER JOIN Photographer ON Photo.PhotogID = Photographer.photogID) INNER JOIN (tSSCat INNER JOIN SSC2Photo ON tSSCat.SSCatID = SSC2Photo.SSCatID) ON Photo.PhotoID = SSC2Photo.PhotoID) ON tSCat.SCatID = tSSCat.SCatID WHERE (((tCat.CatID)=" & request("Cat") & "));"
I substituted the " & request("Cat") & " with the number 24 because there is no form here, so I put in a known ID that displays the entire Ferrari category only.
"SELECT DISTINCT Photo.PDesc, Photographer.Fullname AS Expr1, Photo.PhotoID, Photo.Date, Photo.Size, Photo.Filename, Photographer.photogID, Photographer.GalleryLink FROM Photographer AS Photographer_1, (tCat INNER JOIN tSCat ON tCat.CatID = tSCat.CatID) INNER JOIN ((Photo INNER JOIN Photographer ON Photo.PhotogID = Photographer.photogID) INNER JOIN (tSSCat INNER JOIN SSC2Photo ON tSSCat.SSCatID = SSC2Photo.SSCatID) ON Photo.PhotoID = SSC2Photo.PhotoID) ON tSCat.SCatID = tSSCat.SCatID WHERE (((tCat.CatID)=24));"
The following is a cut down version of the code.
<body>
<table width="100%" border="1">
<thead>
<tr>
<th ALIGN="LEFT"><b>PDesc</b></th>
<th ALIGN="LEFT"><b>Filename</b></th>
<th ALIGN="LEFT"><b>PhotoID</b></th>
<th ALIGN="LEFT"><b>PhotogID</b></th>
</tr>
</thead>
<tbody>
<!--#include file="_fpclass/fpdblib.inc"-->
<%
fp_sQry="SELECT * FROM Photo"
fp_sDefault=""
fp_sNoRecords="<tr><td>No records returned.</td></tr>"
fp_sDataConn=DBConn
fp_iMaxRecords=0
fp_iCommandType=1
fp_iPageSize=5
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_sColTypes="&PDesc=202&Filename=202&PhotoID=3&PhotogID=3&Date=135&Size=202&GalleryPicture=3&"
fp_iDisplayCols=4
fp_fCustomQuery=True
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="_fpclass/fpdbrgn1.inc"-->
<tr>
<td>
<%=FP_FieldVal(fp_rs,"PDesc")%></td>
<td>
<%=FP_FieldVal(fp_rs,"Filename")%></td>
<td>
<%=FP_FieldVal(fp_rs,"PhotoID")%></td>
<td>
<%=FP_FieldVal(fp_rs,"PhotogID")%></td>
</tr>
<!--#include file="_fpclass/fpdbrgn2.inc"-->
</tbody>
</table>
</body>
The first link is the select all query and the second is the big query that fails.
http://www.imagerealm.co.uk/new_page_2.asp
http://www.imagerealm.co.uk/new_page_3.asp
I have a strange problem that has developed recently and wondered if someone could help me here please as I'm completely foxed with this one.
For over a year now I have had a couple of pages that perform filtered category searches that have worked perfectly well all this time and all of a sudden I get a "no records returned" displayed.
I have tested the pages on my local machine it all works fine. However, when I try the searches online it fails every time.
I have tried deleting all the files and re-uploading the entire site, I have created cut down versions without all the bells and whistles all works great locally but not on line.
The pages in question are:
http://www.imagerealm.co.uk/search_f1.asp
http://www.imagerealm.co.uk/search_gen.asp
click on a category on the lower left dropdown and it will display the number of images found and also display the thumbnails. (this is the bit that no longer works.)
Here is an example of a page that does what it should, although the query is slightly different. http://www.imagerealm.co.uk/search_cat.asp?ID=7 It’s a very similar display.
I think the Query is being bounced or something at the ISP.
This code works fine and does retrieve the results using a straight select all
"SELECT * FROM Photo"
When I use the following query it fails to retrieve the results but is fine locally.
"SELECT DISTINCT Photo.PDesc, Photographer.Fullname AS Expr1, Photo.PhotoID, Photo.Date, Photo.Size, Photo.Filename, Photographer.photogID, Photographer.GalleryLink FROM Photographer AS Photographer_1, (tCat INNER JOIN tSCat ON tCat.CatID = tSCat.CatID) INNER JOIN ((Photo INNER JOIN Photographer ON Photo.PhotogID = Photographer.photogID) INNER JOIN (tSSCat INNER JOIN SSC2Photo ON tSSCat.SSCatID = SSC2Photo.SSCatID) ON Photo.PhotoID = SSC2Photo.PhotoID) ON tSCat.SCatID = tSSCat.SCatID WHERE (((tCat.CatID)=" & request("Cat") & "));"
I substituted the " & request("Cat") & " with the number 24 because there is no form here, so I put in a known ID that displays the entire Ferrari category only.
"SELECT DISTINCT Photo.PDesc, Photographer.Fullname AS Expr1, Photo.PhotoID, Photo.Date, Photo.Size, Photo.Filename, Photographer.photogID, Photographer.GalleryLink FROM Photographer AS Photographer_1, (tCat INNER JOIN tSCat ON tCat.CatID = tSCat.CatID) INNER JOIN ((Photo INNER JOIN Photographer ON Photo.PhotogID = Photographer.photogID) INNER JOIN (tSSCat INNER JOIN SSC2Photo ON tSSCat.SSCatID = SSC2Photo.SSCatID) ON Photo.PhotoID = SSC2Photo.PhotoID) ON tSCat.SCatID = tSSCat.SCatID WHERE (((tCat.CatID)=24));"
The following is a cut down version of the code.
<body>
<table width="100%" border="1">
<thead>
<tr>
<th ALIGN="LEFT"><b>PDesc</b></th>
<th ALIGN="LEFT"><b>Filename</b></th>
<th ALIGN="LEFT"><b>PhotoID</b></th>
<th ALIGN="LEFT"><b>PhotogID</b></th>
</tr>
</thead>
<tbody>
<!--#include file="_fpclass/fpdblib.inc"-->
<%
fp_sQry="SELECT * FROM Photo"
fp_sDefault=""
fp_sNoRecords="<tr><td>No records returned.</td></tr>"
fp_sDataConn=DBConn
fp_iMaxRecords=0
fp_iCommandType=1
fp_iPageSize=5
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_sColTypes="&PDesc=202&Filename=202&PhotoID=3&PhotogID=3&Date=135&Size=202&GalleryPicture=3&"
fp_iDisplayCols=4
fp_fCustomQuery=True
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="_fpclass/fpdbrgn1.inc"-->
<tr>
<td>
<%=FP_FieldVal(fp_rs,"PDesc")%></td>
<td>
<%=FP_FieldVal(fp_rs,"Filename")%></td>
<td>
<%=FP_FieldVal(fp_rs,"PhotoID")%></td>
<td>
<%=FP_FieldVal(fp_rs,"PhotogID")%></td>
</tr>
<!--#include file="_fpclass/fpdbrgn2.inc"-->
</tbody>
</table>
</body>
The first link is the select all query and the second is the big query that fails.
http://www.imagerealm.co.uk/new_page_2.asp
http://www.imagerealm.co.uk/new_page_3.asp