English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

2006-12-21 02:44:44 · 4 answers · asked by vishal a 1 in Computers & Internet Programming & Design

4 answers

You can filter records in two ways
1) Use WHERE clause in your select query
2)This method is used for disconnected recordsets. You can use the filter property of a recordset.
e.g. rs.filter="name='xxx'"
You can master this syntax by looking up MSDN online and searching for filter property of ADODB

2006-12-22 09:18:09 · answer #1 · answered by Flirtatious Wiz 2 · 0 0

Tools>Filter

2006-12-21 03:00:54 · answer #2 · answered by SeveralTimesWrong 5 · 0 0

look here:

http://www.w3schools.com/ado/prop_rs_filter.asp
An example using sql query

<%
set conn=Server.CreateObject("ADODB.Connection")
conn.Provider="Microsoft.Jet.OLEDB.4.0"
conn.Open(Server.Mappath("/db/northwind.mdb"))
set rs = Server.CreateObject("ADODB.recordset")
sql="SELECT Companyname, Contactname FROM Customers WHERE CompanyName LIKE 'A%'"
rs.Open sql, conn
%>



<%for each x in rs.Fields
response.write("")
next%>

<%do until rs.EOF%>

<%for each x in rs.Fields%>

<%next
rs.MoveNext%>

<%loop
rs.close
conn.close
%>
" & x.name & "
<%Response.Write(x.value)%>



2006-12-21 03:01:27 · answer #3 · answered by Ana 6 · 0 0

Use the WHERE clause in your SELECT statement.
"SELECT * from table WHERE Name = 'Myron'"

You can chain up with OR or AND to get multiple WHERE selections. You can also use the HAVING clause in place of WHERE.

2006-12-21 03:00:29 · answer #4 · answered by Anonymous · 0 0

fedest.com, questions and answers