0
SELECT count(d.*)
FROM (
    SELECT s.id
        ,avg(e.marks)
    FROM Student s
    INNER JOIN Exam e ON s.id = e.student_id
    GROUP BY s.id
    ) d   

How to represent this for JPA Criteria query to get no of records

Tejal
  • 764
  • 1
  • 10
  • 39
Mahendra
  • 3,647
  • 2
  • 16
  • 16

1 Answers1

0

Looks this is not possible in Criteria Query going ahead with Database view for same

Mahendra
  • 3,647
  • 2
  • 16
  • 16