Anonymous
Anonymous

Reputation: 193

ERD with multiple databases

I want to know, how to design ERD diagrams of two different databases, that have a very strong logical connection between them.

More specifically, I like to model the databases of an evoting system.

For security reasons, I have two different databases. The first one contains the entities voter, candidate , voting, and the second database has only ONE TABLE with three values. the first one is the encrypted candidate ID, the voting No, and the voter ID.

I want to model these two databases. As far I know, an ER is used to model just one DB. How i can model the second DB as well?

Thanks in advance

Upvotes: 1

Views: 2789

Answers (1)

Gilbert Le Blanc
Gilbert Le Blanc

Reputation: 51445

A logical entity relationship diagram doesn't show a particular database or databases. You just model the entities and the relationships.

Vote
--------
Vote Number
Voter ID
Candidate ID 


Voter
----------
Voter ID


Candidate
-----------
Candidate ID
Candidate Name


Office
---------------
Office ID
Office Name


Ballot Section
---------------
Ballot Section ID
Ballot ID
Office ID
Candidate ID


Ballot
------------
Ballot ID
Ballot Name

I'm not sure that you need a Voter table. In an election, the voter information is kept separate from the voting information.

The first column is the primary key of the table.

Subsequent columns with the same name as a primary key are foreign keys.

Upvotes: 3

Related Questions