On Wednesday, February 12, 2020 at 10:32:02 AM UTC-8, BeeRich33 wrote: > > OK, just found something here. > > I have two connections going on. My projects have different connections > belonging to different constants such as DR and DBL. DBL was ahead of this > DR I have here. I moved DR above DBL (which has no :user table), and it > worked. > > Can I not have multiple connections open? >
Multiple connections open is fine. In this case you are talking about multiple Database objects, each of which can have multiple open connections (connections are created as needed). Your issue here is that the first Database instance you create becomes the default for models where you do not specify the Database instance. > I can see a possible conflict where two databases can have the same table > name. In that class declaration, Can I provide a database and table name > as parameters instead of the sole table name? > You can provide a dataset instead of a table name: class User < Sequel::Model(DR[:user]) end Thanks, Jeremy -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/sequel-talk/dde1dd2c-3414-46c2-8db9-80ab131131e2%40googlegroups.com.
