mixcal
1
hello all, i want to ask why does this scipt won’t work
/queue simple
:for i from=1 to= 254 do = {
set [find target-addresses=(“192.168.4.” . $i . “/32”)] max-limit= 64000/384000
};
this won’t work as well
/queue simple
:for i from=1 to= 254 do = {
set [find target-addresses=(“192.168.4.” . $i)] max-limit= 64000/384000
};
i want to change the limit of all ip address in my simple queue with this script. The script execute but won’t change anything. Thanks b4 
dada
2
Hi,
I would use ‘:if’ to see if the ‘find’ found an existing record. Modify only existing records.
mixcal
3
/queue simple
:for i from=1 to= 254 do = {
:if ([/queue simple find target-addresses=(“192.168.4.” . $i)] != “”) do={
set [find target-addresses=(“192.168.4.” . $i)] max-limit= 16000/64000
}
}
thanks a lot it works great. 
another question, what should i write instead of
set [find target-addresses=(“192.168.4.” . $i)] max-limit= 16000/64000
to make the script disable or enable a queue that match the target address?
and does mikrotik have wildcard character? thanks b4 
another question, what should i write instead of
set [find target-addresses=(“192.168.4.” . $i)] max-limit= 16000/64000
to make the script disable or enable a queue that match the target address?
Try,
set [find target-addresses=(“192.168.4.” . $i)] disabled=yes to disable target address
set [find target-addresses=(“192.168.4.” . $i)] disabled=no to enable target address
mixcal
5
thanks a lot it works, anyone know wildcard character in script?