Forum Discussion
Juha__Ranta_106
Nimbostratus
Jun 28, 2005How to iterate over DataGroup List elements ?
Hi,
How can I iterate / access elements of a datagroup ?
I have following 'string data group list' called 'my_str_class':
--- /config/bigip.conf ---
...
Jun 28, 2005
I didn't write the logic behind the data groups but it seems that it is internally represented by a string. By adding the TCL split command to create a true TCL list, foreach should work. I'll verify if this is something we need to fix or if it's by design.
...
foreach i [split $::my_str_class] {
log local0. $i
}
...
As for examples, we're working on that. As for the usage of matchclass, do a search in the forums and you'll find plenty of examples. There is also an example in chapter 13 (Writing iRules) of the BIG-IP v9 user reference.
-Joe
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects