fix search for pg