Begins writing tables