S
Stu
I'm using this code to display results from a database:
<%
companyname = Request.QueryString( "companyname")
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.open "DRIVER={Microsoft Access Driver
(*.mdb)};DBQ=C:mypath\mydatabase.mdb"
quote = "SELECT * FROM Results WHERE company LIKE '%"&
companyname &"%'"
Set quote = Conn.Execute( quote)
if quote.eof then
Response.write("No records found.")
Response.End
end if
%>
The problem I'm having is I'm searching for a company name
and there are more than one record with the same company
name but my results page will only display one record.
Also I'm displaying more fields than just the company
name, but company name is what field is used in the
query. All the fields together are formatted to make up a
quote form. I need this code to display all the records
not just the first one it comes to...and all the other
fields with it. The frontpage database results wizard
does this when you select how many records you want
displayed at one time. If you select 1 then a nav bar is
created at the bottom of the results page to take you to
the next record...this is what I'm trying to
accomplish...but without using the wizard...please help
<%
companyname = Request.QueryString( "companyname")
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.open "DRIVER={Microsoft Access Driver
(*.mdb)};DBQ=C:mypath\mydatabase.mdb"
quote = "SELECT * FROM Results WHERE company LIKE '%"&
companyname &"%'"
Set quote = Conn.Execute( quote)
if quote.eof then
Response.write("No records found.")
Response.End
end if
%>
The problem I'm having is I'm searching for a company name
and there are more than one record with the same company
name but my results page will only display one record.
Also I'm displaying more fields than just the company
name, but company name is what field is used in the
query. All the fields together are formatted to make up a
quote form. I need this code to display all the records
not just the first one it comes to...and all the other
fields with it. The frontpage database results wizard
does this when you select how many records you want
displayed at one time. If you select 1 then a nav bar is
created at the bottom of the results page to take you to
the next record...this is what I'm trying to
accomplish...but without using the wizard...please help