Reduce Array Into Object Oriented Database Example