bug fix for product query