1
0
Fork 0
mirror of https://github.com/yweber/lodel2.git synced 2025-11-14 18:09:17 +01:00

Implemented DropColumn for sqlite

This commit is contained in:
Yann 2015-06-26 16:03:22 +02:00
commit 16a962fb3f
4 changed files with 51 additions and 7 deletions

View file

@ -85,7 +85,8 @@ class EmField(EmComponent):
# @return bool : True if deleted False if deletion aborded
# @todo Check if unconditionnal deletion is correct
def delete(self):
class_table = self.get_class_table()
dbe = self.__class__.getDbE()
class_table = sql.Table(self.get_class_table(), sqlutils.meta(dbe))
field_col = sql.Column(self.name)
ddl = DropColumn(class_table, field_col)
sqlutils.ddl_execute(ddl, self.__class__.getDbE())