Skip to content

Commit

Permalink
Ensure order of tables and relationship (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
syou6162 authored Feb 10, 2024
1 parent 7c99e66 commit c6f27fc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dbterd/adapters/algos/test_relationship.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,7 @@ def parse(manifest, catalog, **kwargs):
logger.info(
f"Collected {len(tables)} table(s) and {len(relationships)} relationship(s)"
)
return (tables, relationships)
return (
sorted(tables, key=lambda tbl: tbl.node_name),
sorted(relationships, key=lambda rel: rel.name),
)

0 comments on commit c6f27fc

Please sign in to comment.