If you run the following script, which is your above script but not in an event, what is your result?

Code
test {
  hadd -m mytable user.adam hi
  hadd mytable user.bob hi
  hadd mytable user.bill hi
  hadd mytable user.chad hi
  tokenize 32 !test mytable user.b*
  var %i = $hfind($2,$3,0,w)
  echo found %i matches
}