I want to get a single predicate which is a string and look at how it is used in a type. All I want is to see a list of all the options where it is used.
This works, but as you can imagine if a bunch of them have the same status then it lists it multiple times. If there are only 10 use cases across 10K uses, I only want the 10, not the 10K. I do not care about any of the uids, I only want the list of unique statuses.
Note: This would be equivalent to the SQL: DISTINCT
A -> M{status: 1, uid: 0xa}
B -> M{status: 1, uid: 0xb}
are they really distinct statuses? Perhaps the graph-ness should be taken into account and when inserting the UID of distinct status messages should be kept?
Kind of funny, conversing right now about how to do traditional GROUP BY with Dgraph to return data from separate trees. Talking about turning the traditional method around because we can get the groups and their data in one call instead of getting their groups and then getting the data in each group with it’s own query. More brain-washing to stop thinking traditional relational database logic. @chewxy, still thinking of the best answer to your question on how to switch from rDBs to graphDBs.