执行SQL语句时获得语法错误

| 我有以下删除数据库的方法,但是出现语法错误,我不知道发生了什么。
public void deleteDB(){
    try{
        Statement s = conn.createStatement();
        System.out.println(\"Deleteting database...\");
        s.execute(\"DROP DATABASE Courses\");
        System.out.println(\"Database deleted.\");
    }
    catch(SQLException error){
        System.err.println(\"Unable to delete database.\");
        error.printStackTrace(System.err);
        System.exit(0);
    }
}
我用以下方法调用该方法:
UpdateDB update = new UpdateDB();
update.connectDatabase(dbName);
update.deleteDB();
我收到此错误:
java.sql.SQLSyntaxErrorException: Syntax error: Encountered \"DATABASE\" at line 1, column 6.
at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException(Unknown Source)
at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
at org.apache.derby.impl.jdbc.EmbedStatement.execute(Unknown Source)
有什么建议么?     
已邀请:
        您有一个名为课程的数据库吗?或名为课程表? 据此:http://db.apache.org/derby/docs/10.0/manuals/develop/develop13.html   没有drop database命令。要删除数据库,请使用操作系统命令删除数据库目录。     

要回复问题请先登录注册