Interface DdlAlterTable
- All Known Implementing Classes:
BaseAlterTableWrite
public interface DdlAlterTable
Object that represents an Alter Table statements. Table alters are grouped together by tableName in DDL and can be extended by
a ddl-specific handler (e.g. doing a reorg for DB2 or implement special grouping for Hana). There is one instance per table.
- Author:
- TODO Roland Praml, FOCONIS AG
-
Method Summary
Modifier and TypeMethodDescriptionAdds an alter table command for given column.booleanFlag that detects if history DDL (switching on) is handled for this table.Adds a raw command.voidSets the history handled flag for this table.voidwrite(Appendable target) Writes the alter table statements totarget
-
Method Details
-
write
Writes the alter table statements totarget- Throws:
IOException
-
append
Adds an alter table command for given column. When you invoke
alterTable(writer, "my_table").add("alter column","my_column).append("type integer")the resulting DDL (in standard implementation) would be
alter table my_table alter column my_column type integer- Returns:
- a DdlBuffer, which can be used for further appends. Note you MUST NOT call
.endOfStatement()on this buffer.
-
raw
Adds a raw command. This is mainly used for executing user stored procedures. -
isHistoryHandled
boolean isHistoryHandled()Flag that detects if history DDL (switching on) is handled for this table. -
setHistoryHandled
void setHistoryHandled()Sets the history handled flag for this table.
-