提交 cf0b53af authored 作者: S.Vladykin's avatar S.Vladykin

Create all tables (temparary as well) with default table engine.

上级 dec792ce
......@@ -5890,8 +5890,6 @@ public class Parser {
command.setTableEngineParams(tableEngineParams);
}
}
} else if (database.getSettings().defaultTableEngine != null) {
command.setTableEngine(database.getSettings().defaultTableEngine);
}
// MySQL compatibility
if (readIf("AUTO_INCREMENT")) {
......
......@@ -328,7 +328,7 @@ public class DbSettings extends SettingsBase {
* (default: null).<br />
* The default table engine to use for new tables.
*/
public String defaultTableEngine = get("DEFAULT_TABLE_ENGINE", null);
public final String defaultTableEngine = get("DEFAULT_TABLE_ENGINE", null);
/**
* Database setting <code>MV_STORE</code>
......
......@@ -8,7 +8,6 @@ package org.h2.schema;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import org.h2.api.ErrorCode;
import org.h2.api.TableEngine;
import org.h2.command.ddl.CreateTableData;
......@@ -16,6 +15,7 @@ import org.h2.constraint.Constraint;
import org.h2.engine.Database;
import org.h2.engine.DbObject;
import org.h2.engine.DbObjectBase;
import org.h2.engine.DbSettings;
import org.h2.engine.FunctionAlias;
import org.h2.engine.Session;
import org.h2.engine.SysProperties;
......@@ -568,7 +568,10 @@ public class Schema extends DbObjectBase {
}
data.schema = this;
if (data.tableEngine == null) {
if (database.getSettings().mvStore) {
DbSettings s = database.getSettings();
if (s.defaultTableEngine != null) {
data.tableEngine = s.defaultTableEngine;
} else if (s.mvStore) {
data.tableEngine = MVTableEngine.class.getName();
}
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论