product management improve DB queries