powered by
dm_has_fk() checks if a foreign key reference exists between two tables in a dm.
dm_has_fk()
dm
dm_has_fk(dm, table, ref_table)
A dm object.
A table in the dm.
The table to be checked if it is referred to.
A boolean value: TRUE if a reference from table to ref_table exists, FALSE otherwise.
TRUE
table
ref_table
FALSE
Other foreign key functions: dm_add_fk(), dm_enum_fk_candidates(), dm_get_all_fks(), dm_get_fk()
dm_add_fk()
dm_enum_fk_candidates()
dm_get_all_fks()
dm_get_fk()
# NOT RUN { dm_has_fk(dm_nycflights13(), flights, airports) dm_has_fk(dm_nycflights13(), airports, flights) # }
Run the code above in your browser using DataLab