Thanks Niels
In my case i never know if anny of the dimension will appear, so my solution was this:
(sum(@"[12]", 0, m1, 0) + sum(@"[13]", 0, m1, 0)
+ sum(@"[14]", 0, m1, 0) + sum(@"[15]", 0, m1, 0)
+ sum(@"[16]", 0, m1, 0) + sum(@"[17]", 0, m1, 0)
+ sum(@"[18]", 0, m1, 0) + sum(@"[19]", 0, m1, 0)
+ sum(@"[20]", 0, m1, 0) + sum(@"[21]", 0, m1, 0)
+ sum(@"[22]", 0, m1, 0) + sum(@"[23]", 0, m1, 0)
+ sum(@"[24]", 0, m1, 0) + sum(@"[25]", 0, m1, 0)
+ sum(@"[26]", 0, m1, 0) + sum(@"[27]", 0, m1, 0)
+ sum(@"[28]", 0, m1, 0) + sum(@"[29]", 0, m1, 0)
+ sum(@"[30]", 0, m1, 0))
Thanks for the help
-Jens henrik