getting all records from backendless in BackendlessCollection<Foo>

Hi ,
I try to fetch 50 records at a time from backendless table and i am not able to find all that in single query.

Currently i am doing this code :
Backendless.Data.of(History.class).find(dataQuery, new LoadingCallback&lt;BackendlessCollection&lt;History&gt;>(getActivity(), "Loading...", true) {
 public void handleResponse(BackendlessCollection&lt;History&gt; historyBackendlessCollection) {
// here i am getting record form server and try to add in arraylist but i get only 10 record in this list

here i am not able to get all record how to do these ?
Please help to solve this .

Add this code before you load any data:

QueryOptions queryOptions = new QueryOptions();
queryOptions.setPageSize( 50 );
dataQuery.setQueryOptions( queryOptions );

Ok ,

Thanks Mark ,
It’s work and helpful for me.

It is not possible to give pagesize > 100 ?

No, 100 is the maximum.

So if i want more than 100 then what i have to do ? Is there any other way to do that?

Use paging API

ok. Thanks

//this is my code i am unable to get more then 10 data in a row.
package com.example.kulwindersingh.kiit.Event_Details;

import android.os.Bundle;
import android.util.Log;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.TextView;
import android.widget.Toast;

import com.backendless.Backendless;
import com.backendless.BackendlessCollection;
import com.backendless.async.callback.AsyncCallback;
import com.backendless.exceptions.BackendlessFault;
import com.backendless.persistence.BackendlessDataQuery;
import com.backendless.persistence.QueryOptions;
import com.example.kulwindersingh.kiit.R;

import java.util.ArrayList;
import java.util.concurrent.CountDownLatch;


  • Created by hp on 8/24/2016.
    public class Ewc extends Activity {
    ListView listView;

    ArrayAdapter<String> adapter1;
    ArrayList<String> course_list = new ArrayList<>();
    TextView tv;

    protected void onCreate(Bundle savedInstanceState) {
    listView = (ListView) findViewById(;

     Backendless.initApp(this, Defaults.APPLICATION_ID, Defaults.SECRET_KEY, Defaults.VERSION);
     BackendlessDataQuery dataQuery = new BackendlessDataQuery();
     QueryOptions queryOptions = new QueryOptions();
     queryOptions.setPageSize( 90 );
     dataQuery.setQueryOptions( queryOptions );
     Backendless.Data.of(EastWestCenter.class).find(dataQuery, new AsyncCallback&lt;BackendlessCollection&lt;EastWestCenter&gt;>() {
         public void handleResponse(BackendlessCollection&lt;EastWestCenter&gt; eastWestCenterBackendlessCollection) {
             for (EastWestCenter ewc : eastWestCenterBackendlessCollection.getData()) {
                 course_list.add(ewc.getSpokesperson() + "\n" + ewc.getAboutEvent());
                 Toast.makeText(Ewc.this, "" + ewc.getSpokesperson(), Toast.LENGTH_SHORT).show();
             adapter1 = new ArrayAdapter&lt;String&gt;(getApplicationContext(), R.layout.contentfetch_layout, course_list);
         public void handleFault(BackendlessFault backendlessFault) {