Hi,
Can be done.
The script will take the next setting, verify whether it is valid. If it is not then mark it as invalid and pick up the next one. Then update the settings table with the values.
What do you want to do with the invalid ones? Remove them, mark them as invalid or just leave them?
Thanks