====== dropColumnSql ====== ~~NOTOC~~ == See Also == [[v5:dictionary:column_attributes|Column Attributes Reference]] == Syntax == array dropColumnSql( string $tableName, string $columnName ) ===== Description ===== The method ''dropColumnSql()'' creates the SQL statement necessary to drop an existing column given by ''$columnName'' from an existing table, given by ''$tableName'. In order to actually create the column, the returned array must be passed to the [[v5:dictionary:executesqlarray|executeSqlArray()]] method. ===== Usage ===== /* * Connection to DB2 database */ $dict = NewDataDictionary($db); $sqlarray = $dict->dropColumnSql('ACT','ACTNOTES'); print_r($sqlarray); /* * Prints Array ( [0] => ALTER TABLE ACT DROP COLUMN ACTNOTES ) */ $dict->executeSqlArray($executeSqlArray);