change way to extract OpenItem data from db and groups base on PLANED data