This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
class CreatePostSimilarities < ActiveRecord::Migration[7.0]
|
||||
def change
|
||||
create_table :post_similarities do |t|
|
||||
t.references :post, null: false, foreign_key: { to_table: :posts }
|
||||
t.references :target_post, null: false, foreign_key: { to_table: :posts }
|
||||
t.float :cos, null: false
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user