Added code to handle schema changes