Create View
V1 as
Select ΚΩΔΒΙΒΛΙΟΥ, count(ΚΩΔΔΑΝ)as PLHTHOS1
From ΔΑΝΕΙΣΜΟΙ
Group by ΚΩΔΒΙΒΛΙΟΥ
Create
View V2 as
Select ΚΩΔΒΙΒΛΙΟΥ, ΤΙΤΛΟΣ, count(ΚΩΔΔΑΝ)as PLHTHOS2
From ΔΑΝΕΙΣΜΟΙ, V1
Where ΔΑΝΕΙΣΜΟΙ.ΚΩΔΒΙΒΛΙΟΥ = V1.ΚΩΔΒΙΒΛΙΟΥ and count(ΚΩΔΔΑΝ) =
(Select MAX(ΚΩΔΔΑΝ) From V1)