[Improved]: Recognise BASE TABLE table type in database metadata (OFBIZ-7129)

git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1771995 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Paul Foxworthy
2016-11-30 06:42:42 +00:00
parent a5c9a1cc7b
commit 40119e0db0
@@ -965,7 +965,7 @@ public class DatabaseUtil {
String lookupSchemaName = null;
try {
String[] types = {"TABLE", "VIEW", "ALIAS", "SYNONYM"};
String[] types = {"TABLE", "BASE TABLE", "VIEW", "ALIAS", "SYNONYM"};
lookupSchemaName = getSchemaName(dbData);
tableSet = dbData.getTables(null, lookupSchemaName, null, types);
if (tableSet == null) {
@@ -1014,7 +1014,8 @@ public class DatabaseUtil {
// NOTE: this may need a toUpperCase in some cases, keep an eye on it, okay for now just do a compare with equalsIgnoreCase
String tableType = tableSet.getString("TABLE_TYPE");
// only allow certain table types
if (tableType != null && !"TABLE".equalsIgnoreCase(tableType) && !"VIEW".equalsIgnoreCase(tableType) && !"ALIAS".equalsIgnoreCase(tableType) && !"SYNONYM".equalsIgnoreCase(tableType)) {
if (tableType != null && !"TABLE".equalsIgnoreCase(tableType) && !"VIEW".equalsIgnoreCase(tableType)
&& !"ALIAS".equalsIgnoreCase(tableType) && !"SYNONYM".equalsIgnoreCase(tableType) && !"BASE TABLE".equalsIgnoreCase(tableType)) {
continue;
}