Find all the makers who have all their models of PC type in the PC table
Here is the typical fallacious query
The key point of the claim is the word «ALL». Let’s analyze the models of Producer E. For PC models, issued by Producer E, we can generate the following query:
And now let’s see, which of the models are provided in PC table:
It appears that out of the three models only one – 1260 – is present in PC table. In accordance with the terms of the problem there should be ALL the three models of producer E.
Namely, solution of this problem boils down to operation of relational division, but for each producer there should be his own factor (set of the models). In the simplified way the operation of relational division can be recorded in the following way:
Operation of relational division is rather primitive. It means that this operation can be represented using other (primitive) relational operations. Redundancy of relational algebra, suggested by Codd, is predetermined by its focus on practical application. SQL(Structured Query Language) is a database computer language designed for the retrieval and management of data in relational database management systems (RDBMS), database schema creation and modification, and database object access control management.SQL language is also redundant, which is proved by every exercise, which can be solved in different ways. However it does not provide any analogue for relational division. :-)
To conclude with I would like to present relational division by means of other operations.
In this respect A[a] means projection of relation A on attribute a; TIMES is Cartesian product. «Verbal» translation of the right part of the equation into SQL language can be represented in the following way:
One should not use this translation as guide to operations; there are some easier ways to solve this problem. However I am not very persistent in this respect. :-)