fixed method bugs; fixed database creation bugs