Search code examples
freebase

How to get mids from freebase


I wanted to know is there any way to retrieve Mids from freebase by query on name, place of birth and years of birth ...

I know that, I can use query like:

query={"type":"/people/person"%2C"id":null%2C"name":"Susan%20Sarandon"%2C"date_of_birth":"1946-10-04"}

and it gives me the: "id" = "/en/susan_sarandon"
but I want: "id": "/m/01vwllw"

And also I need to know date_of_birth, but I only know the place of birth and year of birth and death. Another problem is that I am not sure about the way that they stored the names. I mean it is always something like "Susan Sarandon" or it could be "Susan_Sarandon"?


Solution

  • If you just ask for an ID, Freebase will give you whatever it thinks is best. If you explicitly want an MID (or GUID), you can ask for them, e.g.

    [{
      "type": "/people/person",
      "mid": null,
      "name": "Susan Sarandon",
      "date_of_birth": "1946-10-04"
    }]