I want to bar a range of IP's in a SELECT statement that pulls details from a cookie stats table. We have a range of IP addresses - let's say XXX.XXX.XXX.2 to XXX.XXX.XXX.64 what would the syntax be to not pull the records that do not correspaond to these IP's so as to discount traffic from the office for stat reports. I have tried something along the line of the following:
SELECT TOP 10 URL, COUNT(URL) AS urlcount FROM UserTest WHERE (URL LIKE 'XYZ' AND URL NOT LIKE '%ABC%' AND thetime BETWEEN '8/1/2001' AND '9/1/2001') AND ((Remote NOT LIKE 'xxx.xxx.xxx.64') OR (Remote NOT LIKE xxx.xxx.xxx.65') OR (Remote NOT LIKE xxx.xxx.xxx.66') etc etce etc GROUP BY URL ORDER BY urlcount DESC,URL
It it does not discount enough of the traffic from the office.
Does anyone have any suggestions?