title: How to show data from the cloud firestore in user's phone in android studio?
body: <p><a href="https://i.stack.imgur.com/Ed7q4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ed7q4.png" alt="enter image description here" /></a></p>
  <p>Here is my actual database in the cloud firestore. I want to show these datas in a simple way, just lines of text. I was trying but I only come this far. The request actually reaches to the firestore. But can't fetch the data.<br />
  Also proof that it actually works in logcat:</p>
  <p><a href="https://i.stack.imgur.com/qsVmb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qsVmb.png" alt="enter image description here" /></a></p>
  <pre><code>package com.example.mezuniyet2nat;
  import androidx.annotation.NonNull;
  import androidx.appcompat.app.AppCompatActivity;
  import android.nfc.Tag;
  import android.os.Bundle;
  import android.util.Log;
  import android.widget.ArrayAdapter;
  import android.widget.ListView;
  import android.widget.TextView;
  import com.google.android.gms.tasks.OnCompleteListener;
  import com.google.android.gms.tasks.Task;
  import com.google.firebase.FirebaseApp;
  import com.google.firebase.firestore.FirebaseFirestore;
  import com.google.firebase.firestore.QueryDocumentSnapshot;
  import com.google.firebase.firestore.QuerySnapshot;
  import java.util.ArrayList;
  public class MainActivity extends AppCompatActivity {
  ListView listele;
  String [] dataz;
  //these are not used, I ignored them later.
  
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main);
          final String TAG = &quot;bisey&quot;;
          TextView theTextView= (TextView) findViewById(R.id.tekst);
  
  
          FirebaseFirestore db = FirebaseFirestore.getInstance();
          db.collection(&quot;tablo&quot;)
                  .get()
                  .addOnCompleteListener(new OnCompleteListener&lt;QuerySnapshot&gt;() {
                      @Override
                      public void onComplete(@NonNull Task&lt;QuerySnapshot&gt; task) {
                          if (task.isSuccessful()) {
                              for (QueryDocumentSnapshot document : task.getResult()) {
                                  Log.d(TAG, document.getId() + &quot; =&gt; &quot; + document.getData());
  
                                  String   bisey =  FirebaseFirestore.getInstance().getNamedQuery(&quot;adSoyad&quot;).toString();
  
                                  theTextView.setText(bisey);
                              }
                          } else {
                              Log.w(TAG, &quot;Error getting documents.&quot;, task.getException());
                          }
                      }
                  });
          }
  }
  </code></pre>