rows
rows copied to clipboard
Unable to use schema on rows pgimport
diff --git a/rows/utils.py b/rows/utils.py
index 471e36e..3e7fd98 100644
--- a/rows/utils.py
+++ b/rows/utils.py
@@ -756,7 +757,7 @@ def get_psql_copy_command(
if direction not in ("FROM", "TO"):
raise ValueError('`direction` must be "FROM" or "TO"')
- table_name = slug(table_name)
+ table_name = slug(table_name, permitted_chars=rows.fields.SLUG_CHARS + '.')
if header is None:
header = ""
else:
The final patch should replace "schema.table_name" with "schema"."table_name". The attached patch just doesn't remove the "." (which was being removed by slug function).