Using hook_views_query_alter
Posted on drupal, viewsThere are times that you might want to alter the query that the Views module generates. My problem was to include an attribute filter for products from the Ubercart module. uc_views might be able to do the trick although filters for product attributes were only for products that have already been order. There is also a patch available although I didn't make use of it as I only needed something simple. I decided to use hookviewsquery_alter. It says to put your function MODULENAME_views_query_alter in MODULENAME.views.inc although it seemed to have just been called in my MODULENAME.module. I...