Beatified create database script
Fixed the definitions for the views in the creation script