You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
metadata.add_relationship(
parent_table_name='users',
child_table_name='transactions',
parent_primary_key='user_id', # can be a tuple for composite keyschild_foreign_key='purchaser_id'# can be a tuple for composite key
)
metadata.add_relationship(
parent_table_name='users',
child_table_name='transactions',
parent_primary_key='user_id', # can be a tuple for composite keyschild_foreign_key='start_date'# can be a tuple for composite key
)
Error: Relationshipbetweentables ('users', 'transactions') isinvalid. Theprimaryandforeignkeycolumnsarenotthesame type.
The text was updated successfully, but these errors were encountered:
Problem Description
As a user, it would be helpful to be able to programmatically specify and add relationships between tables in my metadata.
Expected behavior
add_relationship
methodparent_table_name
: A string representing the name of the parent tablechild_table_name
: A string representing the name of the child tableparent_primary_key
: A string or tuple of strings representing the primary key of the parentchild_foreign_key
: A string or tuple of strings representing the foreign key of the childThe text was updated successfully, but these errors were encountered: