Creating the view and subset in TM1

Hello All, Below code is simplified version of IBM Planning Analytics code for creating the source and target TM1 Dimension Subset and TM1 Cube Views. Mainly highlight of this code is 1. MDX 2. Temp Object3. Static Subset