Sha256: 27457898210fb6cfd735e19c7b94eca20be3efbfbb1502264f2398b043354a95
Contents?: true
Size: 208 Bytes
Versions: 10
Compression:
Stored size: 208 Bytes
Contents
module RC module PrimaryKey def add_primary_key(table, options = {}) attribute = "id".to_sym sql = "ALTER TABLE #{table} ADD PRIMARY KEY (#{attribute})" execute(sql) end end end
Version data entries
10 entries across 10 versions & 1 rubygems