Does anyone know how I can use PostgreSQL inheritance (see below) in a Rails migration? I don't mean single table inheritance supported in Rails with the 'type' attribute
Thanks, Chirag
CREATE TABLE cities ( name text, population float, altitude int -- in feet );
CREATE TABLE capitals ( state char(2) ) INHERITS (cities);
In this case, the capitals table inherits all the columns of its parent table, cities. State capitals also have an extra column, state, that shows their state.