Display doctype as a table in another doctype

I have two doctype, one of them is realted to another, like students and classes
But I need display the table of students into class details view. So, I create a new feild in the class doctype with type table and option Students
But when I try to display it. It dislay empty and I want to show the students linked to this class as table
Any one have idea about that, or I need to put script manually?

The embedded table should be a Child Table

If I set it as child table we can’t access to the table from dashboard