Open Closed

Hybrid DB Migrations #3968


User avatar
0
pablotola created
  • ABP Framework version: v6.0.0
  • UI type: Angular
  • DB provider: EF Core

I want to be able to have some tenants in a shared database and others in their own database. I have the contexts separated, do I need to configure the the same DbSets in both contexts if I want the tenant tables also to be in the host database? When creating migrations for the host and the tenant the tables I specify in the tenant context are not being created in the host.


1 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    do I need to configure the the same DbSets in both contexts if I want the tenant tables also to be in the host database?

    Hi, yes you need it, otherwise it won't create the table

Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
Do you need assistance from an ABP expert?
Schedule a Meeting
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v9.2.0-preview. Updated on March 25, 2025, 11:10