Examples of quoteFullyQualifiedName()


Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

                StringBuffer sqlBuffer = new StringBuffer();
                QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                        .getDataMap()
                        .isQuotingSQLIdentifiers());
                sqlBuffer.append("ALTER TABLE ");
                sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
                sqlBuffer.append(" MODIFY ");

                adapter.createTableAppendColumn(sqlBuffer, column);

                return Collections.singletonList(sqlBuffer.toString());
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

     */
    @Override
    public Collection<String> dropTableStatements(DbEntity table) {
        QuotingStrategy context = getQuotingStrategy(table.getDataMap().isQuotingSQLIdentifiers());
        StringBuffer buf = new StringBuffer("DROP TABLE ");
        buf.append(context.quoteFullyQualifiedName(table));           

        buf.append(" CASCADE CONSTRAINTS");
        return Collections.singleton(buf.toString() );
    }

View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

                StringBuilder sqlBuffer = new StringBuilder();
                QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                        .getDataMap()
                        .isQuotingSQLIdentifiers());
                sqlBuffer.append("ALTER TABLE ");
                sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
                sqlBuffer.append(" ALTER COLUMN ");
                sqlBuffer.append(context.quoteString(getColumn().getName()));
                sqlBuffer.append(" NOT NULL");

                return Collections.singletonList(sqlBuffer.toString());
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

                StringBuilder sqlBuffer = new StringBuilder();
                QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                        .getDataMap()
                        .isQuotingSQLIdentifiers());
                sqlBuffer.append("ALTER TABLE ");
                sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
                sqlBuffer.append(" ALTER COLUMN ");
                sqlBuffer.append(context.quoteString(getColumn().getName()));
                sqlBuffer.append(" NULL");

                return Collections.singletonList(sqlBuffer.toString());
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

        }
        QuotingStrategy context =  getQuotingStrategy(status);
        StringBuilder buf = new StringBuilder();
        buf.append("CREATE TABLE ");
       
        buf.append(context.quoteFullyQualifiedName(ent));
     
        buf.append(" (");

        // columns
        Iterator<DbAttribute> it = ent.getAttributes().iterator();
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

                StringBuilder sqlBuffer = new StringBuilder();
                QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                        .getDataMap()
                        .isQuotingSQLIdentifiers());
                sqlBuffer.append("ALTER TABLE ");
                sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
                sqlBuffer.append(" ALTER COLUMN ");
                sqlBuffer.append(context.quoteString(getColumn().getName()));
                sqlBuffer.append(" NULL");

                return Collections.singletonList(sqlBuffer.toString());
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

     */
    @Override
    public Collection<String> dropTableStatements(DbEntity table) {
        QuotingStrategy context = getQuotingStrategy(table.getDataMap().isQuotingSQLIdentifiers());
        StringBuffer buf = new StringBuffer("DROP TABLE ");
        buf.append(context.quoteFullyQualifiedName(table));           
        buf.append(" CASCADE");
        return Collections.singleton(buf.toString());
    }

    /**
 
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

        QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                .getDataMap()
                .isQuotingSQLIdentifiers());
        StringBuilder buf = new StringBuilder();
        buf.append("ALTER TABLE ");
        buf.append(context.quoteFullyQualifiedName(getEntity()));
        buf.append(" DROP CONSTRAINT ");
        buf.append(fkName);

        return Collections.singletonList(buf.toString());
    }
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

        StringBuilder sqlBuffer = new StringBuilder();
        QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                .getDataMap()
                .isQuotingSQLIdentifiers());
        sqlBuffer.append("ALTER TABLE ");
        sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
        sqlBuffer.append(" DROP COLUMN ");
        sqlBuffer.append(context.quoteString(getColumn().getName()));

        return Collections.singletonList(sqlBuffer.toString());
    }
View Full Code Here

Examples of org.apache.cayenne.dba.QuotingStrategy.quoteFullyQualifiedName()

        StringBuilder sqlBuffer = new StringBuilder();
        QuotingStrategy context = adapter.getQuotingStrategy(getEntity()
                .getDataMap()
                .isQuotingSQLIdentifiers());
        sqlBuffer.append("ALTER TABLE ");
        sqlBuffer.append(context.quoteFullyQualifiedName(getEntity()));
        sqlBuffer.append(" ALTER COLUMN ");
        sqlBuffer.append(context.quoteString(getColumn().getName()));
        sqlBuffer.append(" SET NOT NULL");

        return Collections.singletonList(sqlBuffer.toString());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.