Ralph::Schema::DatabaseForeignKey
Represents a foreign key constraint
Constructors
Instance methods
clone
Sourcecopy_with(name _name = @name, from_table _from_table = @from_table, from_column _from_column = @from_column, to_table _to_table = @to_table, to_column _to_column = @to_column, on_delete _on_delete = @on_delete, on_update _on_update = @on_update)
Sourcefrom_column
Source column (the FK column)
from_table
Source table (the table with the FK column)
name
Constraint name (may be nil for SQLite)
on_delete
ON DELETE action (:cascade, :set_null, :restrict, :no_action)
on_update
ON UPDATE action
to_column
Target column (usually the primary key)
to_table
Target table (the referenced table)