title: firebase.database.DatabaseException: Failed to convert value of type java.lang.Long to String
body: <p>[<img src="https://i.stack.imgur.com/LuBWR.png" alt="This is the database">]</p>
  
  <pre><code>firebase.database.DatabaseException: Failed to convert value of type java.lang.Long to String
  </code></pre>
  
  <p>I am trying to add this data to a FirebaserecyclerAdapter and getting this error </p>
  
  <p>Here is the database reference </p>
  
  <pre><code>    databaseReference = FirebaseDatabase.getInstance().getReference().child("questions");
  </code></pre>
  
  <p>this is how I have used the RecyclerViewAdapter</p>
  
  <pre><code>  FirebaseRecyclerAdapter&lt;History, HistoryViewHolder&gt; firebaseRecyclerAdapter = new FirebaseRecyclerAdapter&lt;History, HistoryViewHolder&gt;(
              History.class, R.layout.history_list_item, HistoryViewHolder.class, databaseReference) {
          @Override
          protected void populateViewHolder(HistoryViewHolder viewHolder, History model, int position) {
              viewHolder.setMyanswer(model.getMyAnswer());
              viewHolder.setCorrentAnswer(model.getCorrectAnswer());
              viewHolder.setImageUrl(getApplicationContext(), model.getImageUrl());
  
          }
      };
      recyclerView.setAdapter(firebaseRecyclerAdapter);
  </code></pre>