pastervoip.blogg.se

Sqlite er diagram
Sqlite er diagram







sqlite er diagram

There are some rules and some guidelines.Ī common mistake is to use mathematical operators ( + - * / ) in the table name, whilst when you create the database this will work, when it comes to writing SQL you will start to get errors. Using Lucidchart to create an ERD which shows the tables, links and 'crows-foot' notation of the join type(cardinality) can be seen below.įirstly looking at naming conventions, simply meaning the rules you will apply to how you name your fields and tables.

sqlite er diagram

Each game can only appear once in table 2 but might be played many time so can appear in Table 3 many times or they may never be played therefore may never appear in Table 3 hence a one to zero or many relationship. The same scenario applies to the link between the gameName from 'Table 3' and the gameID in 'Table 2'. This means the join between the player and session table will be a one to zero or many join. Remember if the player is not in 'Table 1' then the same player cannot possibly appear in 'Table 3', therefore the player cannot be in 'Table 1'. This same player can only appear in the 'Table 1' table once, so the playerID can only appear in 'Table 1' once, it must be unique. Firstly looking at the relationship between Table 1 and Table 3 a player can play many games or no games at all, so the playerID can appear in 'Table 3' none or many times.









Sqlite er diagram