lundi 20 septembre 2021

Seperate Database for Users

In my postgreSQL I currently have one database with user and business relevant tables. Our company is planing in future to add more categories, therefor I would like to seperate the categories into individual databases, as most of the data is quiet static once initialized. Below I am a showing an example with cars, please keep in mind that our company services differ much more as Pkw and LorryTruck and need much more extra tables within their scope.

Current State:

  • PostgreSQL:
    • CompanyDB
      • UserTable
      • PkwTable
      • ServiceTable
      • BookingTable

Future State

  • PostgreSQL:
    • UserDB
      • UserTable
    • PkwDB
      • PkwTable
      • ServiceTable
      • BookingTable
    • LorryTruckDB
      • LorryTruckTable
      • ServiceTable
      • BookingTable

My concern is if and how I could connect user relevant Data to the desired databases. In example a user can register for Pkw services and might be later on interested in LorryTruck services. The main goal is also that a user should only register once on our system.

Is this possible or could I design this better?

Please provide your opinion or experiences.

Thank you!

Aucun commentaire:

Enregistrer un commentaire