Currently, we have vbscript and .hta app with SQL Server as backend database.
Our users can search the database with firstname, or lastname, or both. This works very well.
Here is code snip:
Code: Select all
'Take care of sql injection tactics
SQL_query = "SELECT TOP 100 Name, Rel, Estno, dtfild, pub, doc_typet, btyp, bkno, disp, dispdt, PGNO FROM myTable WHERE NAME LIKE '%" & Replace(txtsrch.value, "'", "''") & "%' ORDER BY NAME "
Set rsData = conn.Execute(SQL_query)
Code: Select all
<input type="text" name="txtsrch" size="43"></font></b>
<input id="Gobutton" type="button" language="vbscript" value="Go" />
This way, users will have 3 input boxes.
The current input box that allows users to search by lastname, firstname, or some characters
AND two additional input boxs to enter start date and end date.
The idea is users can still search by curren txtsrch or they can searvh by date range but not by BOTH.
Your assistance is truly appreciated.
--i--