javascript - add OR operator on mql over freebase -
i want create query show artists thay in reggae , rock music try not work..
[{ "id": null, "name": "rock music", "or:name": "reggae", "type": "/music/genre", "/music/genre/artists": [] }]
since you're after artists, i'd recommend turning query inside out , asking artists, not genres. return artists names, ids, , genres artists include genre of rock music or reggae:
[{ "id": null, "name": null, "type": "/music/artist", "genre": [{ "name|=": [ "rock music", "reggae" ] }], "g:genre": [] }]
it's more robust use ids genres rather names in case decides genre should called "rock" instead of "rock music."
Comments
Post a Comment