Skip to content

Commit

Permalink
Add comments, bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
Mause committed May 20, 2021
1 parent 965fa9e commit 3358d14
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions duckdb_engine/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ def on_connect(self):

def ddl_compiler(self, dialect, ddl, **kwargs):
# TODO: enforce no `serial` type

# duckdb doesn't support foreign key constraints (yet)
ddl.include_foreign_key_constraints = {}
return postgres_dialect.ddl_compiler(dialect, ddl, **kwargs)

Expand All @@ -72,9 +74,11 @@ def has_table(self, connection, table_name, schema=None):
return check_existance(connection, "PRAGMA show", table_name, "Table")

def has_sequence(self, connection, sequence_name, schema=None):
# TODO: use better lookup method
return check_existance(connection, "SELECT nextval", sequence_name, "Sequence")

def has_type(self, connection, type_name, schema=None):
# duckdb doesn't support custom types
return False

@staticmethod
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "duckdb_engine"
version = "0.1.3"
version = "0.1.4"
description = ""
authors = ["Elliana <[email protected]>"]
license = "MIT"
Expand Down

0 comments on commit 3358d14

Please sign in to comment.