fixes to make grammar work with the new api
switch to schema.rb from migrations that call .sql files
more work in progress to support the new api
more wip for new api