Fix search table id iteration.