diff options
author | Alexandre Fayolle <alexandre.fayolle@logilab.fr> | 2009-12-14 15:06:01 +0100 |
---|---|---|
committer | Alexandre Fayolle <alexandre.fayolle@logilab.fr> | 2009-12-14 15:06:01 +0100 |
commit | a252b7db2c66ca371902a12f5c57bbda56045113 (patch) | |
tree | 95a61fea89f54361aaf6f5ff1e23d51c0e38c871 | |
parent | 4a1f9990d58e202372a1d4406dfaad59b3d8ddb6 (diff) | |
download | logilab-common-a252b7db2c66ca371902a12f5c57bbda56045113.tar.gz |
moved method so that it is closer to the related methods
-rw-r--r-- | adbh.py | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -187,10 +187,6 @@ class _GenericAdvFuncHelper: def sql_current_timestamp(self): return 'CURRENT_TIMESTAMP' - def sql_create_sequence(self, seq_name): - return '''CREATE TABLE %s (last INTEGER); -INSERT INTO %s VALUES (0);''' % (seq_name, seq_name) - def sql_create_index(self, table, column, unique=False): idx = self._index_name(table, column, unique) if unique: @@ -205,6 +201,10 @@ INSERT INTO %s VALUES (0);''' % (seq_name, seq_name) else: return 'DROP INDEX %s' % idx + def sql_create_sequence(self, seq_name): + return '''CREATE TABLE %s (last INTEGER); +INSERT INTO %s VALUES (0);''' % (seq_name, seq_name) + def sql_drop_sequence(self, seq_name): return 'DROP TABLE %s;' % seq_name |