You are not logged in.

Dear visitor, welcome to Palo Community Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

MarcusL

Intermediate

  • "MarcusL" is male
  • "MarcusL" started this thread

Posts: 13

Date of registration: Jul 17th 2012

Location: Munich

Occupation: Data & Process Manager Consultant

Hobbies: Chess

  • Send private message

1

Monday, September 3rd 2012, 5:04pm

Loop with groovy

Hi together,

if it possible to script a loop with groovy. I tried it, but did´t work.

thx for help
Mit freundlichen Grüßen / Best regards
Marcus

  • "dmarkovic" is male

Posts: 90

Date of registration: Aug 11th 2011

Location: Vienna / Austria

Occupation: Vector SW DV GmbH

  • Send private message

2

Tuesday, September 4th 2012, 9:22am

Hi MarcusL,

yes, it is possilbe. It depands on, what do you want to loop, a list, a range, an array? Maybe you can post your code. :D

Here are some examples:

Source code

1
2
3
4
x = 0
for ( i in [0, 1, 2, 3, 4] ) {
    x += i
}


Source code

1
2
3
4
5
6
def x = 0
def y = 5

while ( y-- > 0 ) {
    x++
}


Regards.
Djordja Markovic
Vector SW DV GmbH

Interessant things:
Internal derby:
http://www.jedox.com/community/palo-foru…14338#post14338
Calculate your cube size:
http://www.jedox.com/community/palo-foru…14406#post14406

Similar threads

Used tags

groovy, loop

Rate this thread