I’m trying to create a model where a few objects can all be linked to
each other through a central linking table. Table structure is like
– model class Computer
create table computers (
– model Class user
create table users (
– model class Desk
create table desks (
– The linking table
create table linkings (
I want to use has_many / belongs_to or some other association to be
able to have any number of objects from different types linked to each
object. I don’t want to create multiple linkings tables for that, as
the more objects I have the increase in number of tables will be huge.
Any way to cleanly solve this?
I tried also with the latest edge with the new polymorphic relations,
but still can’t get it to do work this way.