Concept:
Count the number of EmpIDs corresponding to a particular department and then write as attribute value of Num in new relational schema EC.
Explanation:
SQL query results
EC
|
DeptName
|
Num
|
AA
|
4
|
AB
|
3
|
AC
|
3
|
AD
|
2
|
AE
|
1
|
AVG(EC. Num) will find out the average of Num values in the returned query.,
\(Average = \;\frac{{4 + 3 + 3 + 2 + 1}}{5} = 2.6\)