You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@empire-db.apache.org by "Francis De Brabandere (JIRA)" <em...@incubator.apache.org> on 2011/04/08 12:03:13 UTC
[jira] [Updated] (EMPIREDB-104) Create DDL Script on MSSQL should
state not CREATE DATABASE if already exist
[ https://issues.apache.org/jira/browse/EMPIREDB-104?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Francis De Brabandere updated EMPIREDB-104:
-------------------------------------------
Fix Version/s: empire-db-2.2.0-incubating
> Create DDL Script on MSSQL should state not CREATE DATABASE if already exist
> ----------------------------------------------------------------------------
>
> Key: EMPIREDB-104
> URL: https://issues.apache.org/jira/browse/EMPIREDB-104
> Project: Empire-DB
> Issue Type: Bug
> Components: Core
> Affects Versions: empire-db-2.1.0-incubating
> Reporter: Ghislain Geffroy
> Assignee: Francis De Brabandere
> Fix For: empire-db-2.2.0-incubating
>
>
> Same type of error than EMPIREDB-101.
> A way to solve the problem is to replace in org.apache.empire.db.sqlserver.DBDatabaseDriverMSSQL$createDatabase() the line
> script.addStmt("CREATE DATABASE " + databaseName);
> by
> script.addStmt("IF NOT EXISTS(SELECT * FROM sys.databases WHERE name = '" + databaseName + "') CREATE DATABASE " + databaseName);
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira