DML – Join Tables

Syntax:

SELECT * FROM result;

SELECT DISTINCT * FROM result, grade

WHERE result.grade = grade.score;

 

Note:

  • The cardinality of the resultant relation instance is equal to that of the result table.
  • If we project the resultant table on scale we do not get all the scale rows.

 

Semantics:

For each row in the result table find the row in the grade table such that the result's grade value is equal to that of the grade's scale value.

 

Syntax:

SELECT DISTINCT *

FROM result, grade;

 

Note:

This is an expensive operation!

 

Semantics:

Each row of the result table is concatenated with each row of the grade table.

kaizenlogadmin (2863 Posts)

I am Peter, a blogger, SEO and social media person who has an interest in E-commerce, ERP and CMS systems. You can contact me by e-mail: kaizenlog@gmail.com