I want to keep track of movies that exist in different formats (for example, DVD, Bluray, etc.). The price for each format differs from the others as well as the quantity of each format, so I came up with the entity-relationship diagram (ERD) shown below:
Is this correct from a design perspective? Does this implies redundancy? I don't understand how will this be retained in a table when implemented in a relational database.
Would it be better to do it like in the diagram that follows:
Here's more descriptive information about what I want to store at this point of the design:
I want to store information about sales.
For each movie that exists in the company I need to keep format, price and stock quantity.
I will also need to maintain customer information with a unique id, name, surname, address, movies that he/she has already bought and his/her credit card number.
Finally, I will have a basket that temporary keeps items (let's suppose that other items exist apart from movies) that the customer wants to buy.