Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2012-11-20 05:44:29 -0500
committerEike Stepper2012-11-20 05:44:29 -0500
commit4c013a92488ef172679f6dbe25a61cbb3024afbb (patch)
tree5a3badc4488622957c2581207c8f9049cc0e92ae /plugins/org.eclipse.net4j.db.oracle
parent1daa7d658da13e0840a9bc27bcf38763ccbbe9c9 (diff)
downloadcdo-4c013a92488ef172679f6dbe25a61cbb3024afbb.tar.gz
cdo-4c013a92488ef172679f6dbe25a61cbb3024afbb.tar.xz
cdo-4c013a92488ef172679f6dbe25a61cbb3024afbb.zip
[394633] [DB] Postgres truncates table/indexes names to 64 characters
https://bugs.eclipse.org/bugs/show_bug.cgi?id=394633
Diffstat (limited to 'plugins/org.eclipse.net4j.db.oracle')
-rw-r--r--plugins/org.eclipse.net4j.db.oracle/src/org/eclipse/net4j/db/oracle/OracleAdapter.java57
1 files changed, 0 insertions, 57 deletions
diff --git a/plugins/org.eclipse.net4j.db.oracle/src/org/eclipse/net4j/db/oracle/OracleAdapter.java b/plugins/org.eclipse.net4j.db.oracle/src/org/eclipse/net4j/db/oracle/OracleAdapter.java
index 2b05c4ba3a..39c74fc049 100644
--- a/plugins/org.eclipse.net4j.db.oracle/src/org/eclipse/net4j/db/oracle/OracleAdapter.java
+++ b/plugins/org.eclipse.net4j.db.oracle/src/org/eclipse/net4j/db/oracle/OracleAdapter.java
@@ -14,25 +14,18 @@ package org.eclipse.net4j.db.oracle;
import org.eclipse.net4j.db.DBException;
import org.eclipse.net4j.db.DBType;
import org.eclipse.net4j.db.ddl.IDBField;
-import org.eclipse.net4j.db.ddl.IDBIndex;
-import org.eclipse.net4j.db.ddl.IDBTable;
-import org.eclipse.net4j.db.oracle.internal.bundle.OM;
import org.eclipse.net4j.spi.db.DBAdapter;
-import org.eclipse.net4j.util.om.trace.ContextTracer;
import javax.sql.DataSource;
import java.sql.Driver;
import java.sql.SQLException;
-import java.sql.Statement;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
public class OracleAdapter extends DBAdapter
{
- private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_SQL, DBAdapter.class);
-
public static final String NAME = "oracle"; //$NON-NLS-1$
public static final String VERSION = "11.1.0.7"; //$NON-NLS-1$
@@ -59,56 +52,6 @@ public class OracleAdapter extends DBAdapter
}
}
- @Override
- protected void createIndex(IDBIndex index, Statement statement, int num) throws SQLException
- {
- IDBTable table = index.getTable();
- StringBuilder builder = new StringBuilder();
- builder.append("CREATE "); //$NON-NLS-1$
- if (index.getType() == IDBIndex.Type.UNIQUE || index.getType() == IDBIndex.Type.PRIMARY_KEY)
- {
- builder.append("UNIQUE "); //$NON-NLS-1$
- }
-
- builder.append("INDEX I"); //$NON-NLS-1$
- builder.append(System.currentTimeMillis());
-
- try
- {
- Thread.sleep(1);
- }
- catch (InterruptedException ex)
- {
- OM.LOG.error(ex);
- return;
- }
-
- builder.append("_");
- builder.append(num);
- builder.append(" ON "); //$NON-NLS-1$
- builder.append(table);
- builder.append(" ("); //$NON-NLS-1$
- IDBField[] fields = index.getFields();
- for (int i = 0; i < fields.length; i++)
- {
- if (i != 0)
- {
- builder.append(", "); //$NON-NLS-1$
- }
-
- addIndexField(builder, fields[i]);
- }
-
- builder.append(")"); //$NON-NLS-1$
- String sql = builder.toString();
- if (TRACER.isEnabled())
- {
- TRACER.trace(sql);
- }
-
- statement.execute(sql);
- }
-
public String[] getReservedWords()
{
List<String> list = new ArrayList<String>(Arrays.asList(getSQL92ReservedWords()));

Back to the top