It's not clearing the codes. You can read if there are any faults with sensors on your car. The ECU has a self check mode.
You can make a small rig up to read the codes for a few pennys. Go to
www.bigturbo.co.uk and it tells you under 'fault codes' how to check and read them.
Then, if you have any faults, you can fix them from there.