I want to retrieve data in ascending order, but received data somehow added to recyclerview in descending order.
Firebase Database:
To get a sorted and filtered result, you have to pass a query into the FirebaseRecyclerAdapter constructor:
public MyFireAdapterDiasFiestaRecyclerView(
Class modelClass,
int modelLayout,
Class viewHolderClass,
Query query) {
...
And then invoke it with a query that orders and filters:
adapter = new MyFireAdapterDiasFiestaRecyclerView(
DiaFiestaMeta.class,
layout_that_you_use,
MyFireViewHolder.class,
ref.orderByChild("property_to_sort_and_filter_on").equalTo("value_to_filter_on")
);