making the simulation-casting page work (first page in casting process that checks ready_p). Adding proc simulation::template::ready_for_casting_p. Refactoring proc simulation::template::edit to do dynamic sql.
make upgrade scripts work, make it a little safer for accidental resourcing (so it won't step on existing usernames), drop views, patch 391 Robert Gaszewski