How to code multi-dimensions data stream in each record