hi
i would like to use queries more frequently. problem is that i do not understand all that is written on wiki.
considder following examples:
i have a routerboard with 5 ethernet interfaces, 1 wlan, 1 bridge
print all interfaces that are not type=wlan and type=bridge
/interface/print
=.proplist=type,.id
?type=wlan
?#!
?type=bridge
?#|
above works well
but this one:
/interface/print
=.proplist=type,.id
?type=wlan
?#!
?type=bridge
?#!
?#|
should return all interfaces that are not in type= wlan,bridge. i should get all ethernet interfaces only. in return i get all interfaces. it doesn’t make sense to me.
/interface/print
=.proplist=type,.id
?type=wlan
?type=bridge
?#|!
this one returns all ethernet interfaces only.
/interface/print
=.proplist=type,.id
?type=wlan
?type=bridge
?#&!
this returns all interfaces.
how does it correspond to De Morgan’s law ?
! character replaces top value with the opposite.
from what is written you can understand that ! character always corresponds to the item at index = 0. if it does how to negate items at other indexes ?
what is a “top value” ?
on wiki in table where operations are described word ‘character’ is frequently used. what kind of character ? what characters are allowed ?
/interface/print
=.proplist=type,.id
?type=wlan
?#!
?type=bridge
?#!
?#|
in above example indexes in stack are:
?type=wlan has stack index = 0
?type=bridge has stack index = 1
am i correct ?
index that is followed by a character pushes copy of value at that index.
again the question. witch character ?
index that is followed by the end of word replaces all values with the value at that index.
if i write:
/interface/print
?type=wlan
?name=bridge
?#0
it will be transformed into:
/interface/print
?type=wlan
?name=wlan
am i right ?
sequence of decimal digits followed by any other character or end of word is interpreted as a stack index. top value has index 0.
what does it mean ?
000101023123!
“000101023123” is a sequence of decimal digits
what index is it ?
. after another character pushes copy of top value.
so it means that a “.” will always point in value at stack index = 0 ?