Reverted to rev 1.4 keys had been mistakenly deleted.
[phpeclipse.git] / archive / net.sourceforge.phpeclipse.sql / src / net / sourceforge / phpdt / sql / adapters / DB2Adapter.java
1 package net.sourceforge.phpdt.sql.adapters;
2
3 public class DB2Adapter extends DatabaseAdapter {
4     public String getShowTableQuery(DatabaseInfo info) {
5         return "SELECT TABNAME FROM syscat.tables WHERE tabschema = '" + info.getSchema().toUpperCase() + "' AND TYPE='T'"; //$NON-NLS-1$ //$NON-NLS-2$
6     }
7     public String getShowViewQuery(DatabaseInfo info) {
8         return "SELECT TABNAME FROM syscat.tables WHERE tabschema = '" + info.getSchema().toUpperCase() + "' AND TYPE='V'"; //$NON-NLS-1$ //$NON-NLS-2$
9     }
10     public String getShowSequenceQuery(DatabaseInfo info) {
11         return "SELECT SEQNAME FROM sysibm.syssequences WHERE seqschema = '" + info.getSchema().toUpperCase() + "'"; //$NON-NLS-1$ //$NON-NLS-2$
12     }
13     public String getNextValue(String sequence) {
14         return "VALUES NEXTVAL FOR " + sequence; //$NON-NLS-1$
15     }
16 }