compare count nodes and ids