should be an array of $ids then use implode(',', $ids)