iRule coding

Hi…don’t know much about coding in F5 just wanted to verify if this works as a negation (!) as in below.

elseif { [matchregion ldns !“BXB-IDMS-DNS”] } { if { [active_members pl_chi-mysql-read.gtm.intdata.com_3306] > 0 } {…

Thanks

I believe you’ll need to move the not outside of the braces:

elseif { not [matchregion ldns "BXB-IDMS-DNS"] } { 
 if { [active_members pl_chi-mysql-read.gtm.intdata.com_3306] > 0 } {....

Thanks Cory. Shall I use the “not” or “!” or either will work?

Either one will work. Sometimes it’s easier to understand upon glancing at it when you spell it out instead of using symbols. End result is the same though.

thank you very much.