Hey,

We're trying to use sequel against a view in Postgres which goes cross 
schema (select * from schema.table basically).  There's a relationship in 
one model 'tickets' (based on the view) which links to another table via a 
`many_to_many`:

```
many_to_many :tags, left_key: :ticket_id, right_key: :tag_id
```

(tickets is a view on a table in another schema, tags is just public.tags)

However, on application boot, this causes an error:

```
17:25:23 web.1    | [32073] ! Unable to load application: Sequel::Error: 
mismatched number of left keys: [:ticket_id] vs []
17:25:24 web.1    | 
/Users/neil/.rbenv/versions/2.2.0/lib/ruby/gems/2.2.0/gems/sequel-4.19.0/lib/sequel/model/associations.rb:1806:in
 
`def_many_to_many': mismatched number of left keys: [:ticket_id] vs [] 
(Sequel::Error)
```

Everything is fine and working in postgres-land and behaving as it should, 
but Sequel is blocking us by causing this error.  I assume this is 
something to do with the schema change in the view?

How can we resolve this?

TIA

Neil


-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to