Thanks for your reply. The data model is the same: https://github.com/iliriani/Test/blob/main/Notebook.rdf
The issue is just how to get all the nested <attribute> that belongs to a specific <class> e.g. "Teacher" in this data model? For instance, as I said the end result should give me for class "Teacher" this results: - id - Emri - Mbiemri - Lendet - Evaluations - User On 2021/04/27 13:41:31, Lorenz Buehmann <[email protected]> wrote: > Maybe I'm mixing up things, but didn't have the same question(s) and > data model some time ago? > > On 27.04.21 15:11, emri mbiemri wrote: > > The "Teacher" node is within a <class> node and the "Teacher" class > > contains the <attribute> node but I don't know how to get all these > > attributes due to the complex model format. > > > > On 2021/04/27 13:00:38, Andy Seaborne <[email protected]> wrote: > >> There isn't a class Teacher in the file - there is a string "Teacher" in > >> a couple of places. > >> > >> Try writing the file out in a format that is easier to look at: > >> > >> Command line: > >> > >> riot --pretty Turtle Notebook.rdf > >> > >> To query for all classes: > >> > >> sparql --data ~/Desktop/Notebook.rdf 'SELECT DISTINCT ?T { ?x a ?T }' > >> > >> Andy > >> > >> On 27/04/2021 11:55, emri mbiemri wrote: > >>> Dears, > >>> > >>> I am trying to query a specific RDF file. I need this solution for my > >>> studies. > >>> > >>> The file I have to work with is: > >>> https://github.com/iliriani/Test/blob/main/Notebook.rdf > >>> > >>> I am trying to get somehow all the attributes of a given class within > >>> this model. But cannot find the right query! > >>> > >>> For instance, I want to get all attributes of class "Teacher", it should > >>> return me: > >>> - id > >>> - Emri > >>> - Mbiemri > >>> - Lendet > >>> - Evaluations > >>> - User > >>> >
