hi Brenden,
thank you for the reply. so your suggesting to use simple repeater instead of smart search ?
actually I know I can do this, even I have the query to do this with repeater but I want to use it in the smart search feature. let me give you a detail on my requirement,
in my advanced search page I have few smart search filter with smart search dialog & smart search result, all of them work well
now I want to add a another dropdown list which let user to select the radius (1 mil, 10 mil etc)
so when search it will search from user current location with the radius.
is that possible to add a custom smart search filter which add some query in the main query which calculate the distance & find listing based on selected radius. My query as following
Declare @latitude decimal(11,6)
Declare @longitude decimal(11,6)
declare @radius int
declare @radiusDataCount int
declare @requestedDataCount int
declare @pageType varchar(100)
set @latitude=51.509865;
set @longitude= -0.118092;
set @radius=15;
set @requestedDataCount = 15;
set @pageType = 'Dev.CompanyDetail'
DECLARE @source geography = 'POINT(-0.118092 51.509865)'
SELECT TOP (@requestedDataCount) Name, [CompanyLatitude],[CompanyLongitude],
GEOGRAPHY::Point([CompanyLatitude], [CompanyLongitude], 4326).STDistance(@source)/1609.344 AS DistanceMile
FROM Dev_CompanyDetail
INNER JOIN [View_CMS_Tree_Joined] AS T ON CompanyID= T.DocumentForeignKeyValue
WHERE [CompanyLatitude] IS NOT NULL
AND (T.DocumentNamePath NOT LIKE '%/Unapproved listing/%'
AND T.ClassName = @pageType
)
ORDER BY DistanceMile ASC