A PHP Error was encountered

Severity: Notice

Message: Trying to get property of non-object

Filename: models/viewfunc.php

Line Number: 174

Database Error

A Database Error Occurred

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and location2.id=1' at line 1

select ProviderCats.title,ProviderCats.keywords,ProviderCats.metadesc, location2.location from ProviderCats,location2 where ProviderCats.CatId = and location2.id=1