Complex/compound sql on Z/OS does not work

I was reading through the wiki on how to create anonymous stored proc/ complex sql using sql pl. The article states that I can do so using being atomic. However, when I tried that on db2 z/so 10, it does not work. Has anyone get it to work successfully? Or is there a workaround to that? Thanks.