How to find nodes given an array of values

UPDATE(2020): if you are reading this. Take into account that Dgraph has changed a lot since this post. Some answers and tips here are just examples. For sure you can do the same thing mentioned here in the comments in other ways. For example, a list of strings can be passed via DQL Variable(which was called “graphql variable” back then). You can pass a list of string-like $mylist='[loren, lorem, loren]' and this will be accepted in the DQL variable as a list of args.

This question is somewhat ambiguous, could not understand well.

If you want to find several nodes matching to single value. This is a simple query. You can mix with Has, regexp, Inequality, Connectives (AND, OR and NOT) and so on.
e.g:

{
  names(func: has(email)) @filter(regexp(email /@some.com/i)) {
    name
    email
  }
}

You gonna have an array.

In the query ask for the email and the name at the same time. Otherwise you will make several queries later (or a great extra).

Dgraph generally only delivers an array of requested nodes (per query and/or query block). All work of treatment of the result has to be done via application. Some things can be done with Dgraph, but you need to understand the whole language “GraphQL + -”.

Check One JS example with Dgraph-js for beginners. Using graphQL instead of REST
There are two examples to which you can get what you need.

Cheers.