0

I have run the following query in the Freebase MQL query editor:

[{ 

"id" : "/en/barack_obama",
"/type/reflect/any_master":
[{ "link" : null,
"name" : null }],
"limit": 200  

}]​

I believe this should return all the links that originate from Barack Obama and whose destiantion is a topic. While it does return the links, it fails to return the children of Barack Obama which is also a link, right? Why does it fail to return this link?

London guy
  • 27,522
  • 44
  • 121
  • 179

1 Answers1

1

The query is returning the complete set of results that you asked for. There are three things wrong with it for the purpose you are trying to use it for:

  1. The limit clause is in the wrong place
  2. The President Obama topic has many more than 200 links, both outgoing (558) and incoming (1527)
  3. The relationship that you're looking for is the reverse of the /people/person/parent relationship, so you need to use any_reverse, not any_master

This query will find the relationship you're looking for:

[{
  "id": "/en/barack_obama",
  "/type/reflect/any_reverse": [{
    "link":  null,
    "name":  null,
    "limit": 1600
  }]
}]​
Tom Morris
  • 10,490
  • 32
  • 53