Skip to main content

Selecting Specific Predicates

So far, we've been using ["*"] to select all the predicates from the subjects we've been querying. We can also select particular predicates.

For example, to get every actor's name (actor/name), we can issue:

{
"select": ["actor/name"],
"from": "actor"
}

Or to get every actor's name and every actor's gender, we could issue:

{
"select": ["actor/name", "actor/gender"],
"from": "actor"
}

Or to get the name and gender from the subject with id, 1891652, we could issue:

{
"select": ["actor/name", "actor/gender"],
"from": 1891652
}

In order to get specific predicates, we could just list as many predicates as we want within the select array.

Querying Titanic

Can you select the just the `movie/credits` and `movie/title` from the movie `Titanic` (`movie/title`)?