title: Getting AWS DynamoDB Number data type using DynamoDB SDK
body: <p>I'm to the AWS Android DynamoDB SDK and lately I encounter a problem and still cannot fix it. 
  When trying to get the 'Created' value of my DynamoDB I get the following error message:<strong>" Expected S in value {N: 1449848553974,} "</strong>.
  What I know so far from the AWS documentation is that <em>'N'</em> stand for the Datatype <em>Number</em>. </p>
  
  <p>Here is the code of the Class:</p>
  
  <pre><code>@DynamoDBTable(tableName = "dev.records_log")
  public class Record
  {
  private Created created;
  
  @DynamoDBAttribute(attributeName = "created")
  @DynamoDBMarshalling(marshallerClass = TimeStampConverter.class)
  public Created getTimestamp_created() 
  {
     return created;
  }
  
  @DynamoDBMarshalling(marshallerClass = TimeStampConverter.class)
   public void setRecord_created(Created created) {
          this.created = created;
      }
  </code></pre>
  
  <p>Hope someone could help me out with this issue. I browse through the internet but with no positive results.</p>
  
  <p><strong>Update:</strong>
  So far I can see in the DynamoDB it is a <em>Unix Timestamp</em> value of the type 'Number'. </p>
  
  <p><a href="https://i.stack.imgur.com/g0WyQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/g0WyQ.png" alt="enter image description here"></a></p>
  
  <p><strong>TimeStamp Class:</strong>
  For the Timestamp class I just implement the DynamoDBMarshaller interface and put some log File to check if the data is received accordingly. </p>
  
  <pre><code>public class TimeStampConverter implements DynamoDBMarshaller&lt;AdditionalInformation&gt;
  {
  
  @Override
  public String marshall(Created created)
  {
       Log.i("LOG","Marshall create value: "+created);
      return null;
  }
  
  @Override
  public Created unmarshall(Class&lt;Created&gt; clazz, String obj) {
  
      Log.i("LOG","Created unmarshall ");
      Created date_time_created = new Created();
      Log.i("LOG","date_time_created "+date_time_created);
      Log.i("LOG","unmarshall s value "+s);
      Log.i("LOG","unmarshall s length "+s.length());
      try{
          if (s != null &amp;&amp; s.length() != 0)
          {
              String[] data = s.split(" ");
              date_time_created.setDate_created(data[0].trim());
              date_time_created.setTime_created(data[1].trim());
  
          }
      }catch (Exception e)
      {
          Log.i("LOG","unmarshall error "+e.getMessage());
          e.printStackTrace();
      }
  
      return date_time_created;
   }
  }
  </code></pre>
  
  <p><strong>Created Class:</strong></p>
  
  <pre><code>public class Created
  {
      private String date_created;
      private String time_created;
  
  public String getDate_created() {
      return date_created;
  }
  
  public void setDate_created(String date_created) {
      this.date_created = date_created;
  }
  
  public String getTime_created() {
      return time_created;
  }
  
  public void setTime_created(String time_created) {
      this.time_created = time_created;
  }
  </code></pre>
  
  <p>}</p>
  
  <p>Thanks in advance.</p>