title: "IN" statement in dynamodb
body: <p>I have a "Users" table, here is a sample : </p>
  
  <pre class="lang-js prettyprint-override"><code>{
      username:"haddox",
      formattedPhoneNumber:"676767676",
      verified: 0,
  }
  </code></pre>
  
  <p>My wish is to retrieve all users whose formattedPhoneNumber is contained in an array of phone numbers (retrieved from my contacts). I created a secondary index, with verified as HASH and formattedPhoneNumber as RANGE. Here is my try : </p>
  
  <pre class="lang-js prettyprint-override"><code>var params = {
      TableName: "Users",
      IndexName: "FormattedPhoneSecondaryIndex",
      KeyConditionExpression: "verified  = :v AND formattedPhone IN :n",
      ExpressionAttributeValues: {
          ":v":1,
          ":n": ["672053916", "642117296"]
      },
      ProjectionExpression: "username, formattedPhoneNumber"
  };
  
  
  
  dynamodb.query(params, function(err, data) {
      if (err)
          console.log(JSON.stringify(err, null, 2));
      else
          console.log(JSON.stringify(data, null, 2));
  });
  </code></pre>
  
  <p>But I get the following error : <code>Invalid KeyConditionExpression: Syntax error; token: \":n\", near: \"IN :n\"",</code>  </p>
  
  <p>Is there something wrong with the IN keyword ? 
  Maybe there is another way to achieve this ?</p>