You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello. So I'm trying to make something like tenancy but not fully.
I have that table structure in my main (system) database:
Offices:
- id
- name
- description
- district_uuid (string)
Districts:
- id
- uuid (string) (related to `Offices.district_uuid`)
- display_name
- database_name (Every district has his own database)
And my other migrations for every database are structured like this:
Tablename:
- column1
- column2
- office_id (related to Main Offices table.)
So i want every model that has office_id to make insert,write,create,delete queries to the correct database based on office->district->database_name.
I also has read & write connections.
Is that going to make the issue more bigger ?
Please give me any suggestions. Can I use this package or I must to coding this logic myself. :)
This discussion was converted from issue #76 on April 18, 2021 14:19.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello. So I'm trying to make something like tenancy but not fully.
I have that table structure in my main (system) database:
And my other migrations for every database are structured like this:
So i want every model that has office_id to make
insert
,write
,create
,delete
queries to the correct database based onoffice->district->database_name
.I also has
read & write
connections.Is that going to make the issue more bigger ?
Please give me any suggestions. Can I use this package or I must to coding this logic myself. :)
Beta Was this translation helpful? Give feedback.
All reactions