1 = Composite Primary Keys for ActiveRecords
\r
5 ActiveRecords/Rails famously doesn't support composite primary keys.
\r
6 This RubyGem extends the activerecord gem to provide CPK support.
\r
10 gem install composite_primary_keys
\r
14 require 'composite_primary_keys'
\r
15 class ProductVariation
\r
16 set_primary_keys :product_id, :variation_seq
\r
19 pv = ProductVariation.find(345, 12)
\r
21 It even supports composite foreign keys for associations.
\r
23 See http://compositekeys.rubyforge.org for more.
\r
27 See test/README.tests.txt
\r
31 http://compositekeys.rubyforge.org
\r
33 == Questions, Discussion and Contributions
\r
35 http://groups.google.com/compositekeys
\r
39 Written by Dr Nic Williams, drnicwilliams@gmail
\r
40 Contributions by many!
\r