parent
1a4d43dbbf
commit
bec8cea3e3
@ -65,6 +65,7 @@ class Postgresql:
|
||||
query = query.replace("?", "%s")
|
||||
query = query.replace("REGEXP", "~")
|
||||
query = query.replace("desc", "desc_")
|
||||
query = query.replace("BLOB", "bytea")
|
||||
## LIMIT offset, count
|
||||
## count can be -1, for all
|
||||
## LIMIT -1
|
||||
@ -114,7 +115,7 @@ class Postgresql:
|
||||
def table_exists(self, table):
|
||||
self.__cursor.execute("SELECT COUNT(*) "
|
||||
"FROM information_schema.tables "
|
||||
"WHERE table_name=?;", [table])
|
||||
"WHERE table_name=%s;", [table])
|
||||
return self.fetchone()[0] != 0
|
||||
|
||||
def close(self):
|
||||
|
Loading…
Reference in New Issue
Block a user