Add advanced option to clear database.

Add check for refresh upon old data.