Fix bug with writeOffMethod in create database script