Check and Fix ids. First step.