Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-05-13 : 00:50:48
|
| hi all,I want to find the top 5 searches from the Searched Table,user can search records with zip code, (city and state) and or nameMy idea is i can have a temp table insert searched record into it and increment in the "NoOfTimeSearched" columnThe temp table fields will be Id, Date, zip, city, state, name, NoOfTimeSearched,Please suggest me how can i get this using stored procedure |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-05-13 : 10:16:34
|
| add parameters in stored procedure for passing search values of zip code, (city and state) and or name and then while retrieving insert the matching records to temp table if not already present with 1 as value for NoOfTimeSearched. and if record is already present just increment NoOfTimeSearched value by 1. |
 |
|
|
|
|
|