I am working on this issue No way to return quads in dgraph · Issue #118 · dgraph-io/dgraph · GitHub and trying to understand the code involved in it better.
I suppose we could have _label_
as a predicate that one could ask for. Though it won’t be allowed at the top level as it is associated with a S O P. Since all our predicates right now have a posting list corresponding to them, and _label_
won’t have one. We would have to handle it separately.
{
me(_uid_: 0x01) {
friend {
_label_
name
}
name
gender
status
}
}
The way I understand is that currently it is stored as part of the value in the posting list. Is that correct @mrjn?
Update - Its stored as part of a Posting as the Source(string). Understood that now on reading more about it. Now have to see how to retrieve and return it. Had almost forgotten that flatbuffer structures like Query, Result, Posting have a schema too.