Skip to content

Commit 036e0f2

Browse files
committed
Remove unnecessary ON DUPLICATE KEY UPDATE in insert_lineage_entries
1 parent b568997 commit 036e0f2

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/datajoint/lineage.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,14 +100,12 @@ def insert_lineage_entries(connection, database, entries):
100100

101101
ensure_lineage_table(connection, database)
102102

103-
# Use INSERT ... ON DUPLICATE KEY UPDATE to handle re-declarations
104103
for table_name, attribute_name, lineage in entries:
105104
connection.query(
106105
f"""
107106
INSERT INTO `{database}`.`{LINEAGE_TABLE_NAME}`
108107
(table_name, attribute_name, lineage)
109108
VALUES (%s, %s, %s)
110-
ON DUPLICATE KEY UPDATE lineage = VALUES(lineage)
111109
""",
112110
args=(table_name, attribute_name, lineage),
113111
)

0 commit comments

Comments
 (0)