1

I have the following code but I don't what method to use something like .notEqualsto(uid)

public class CustomAdapter extends FirebaseRecyclerAdapter<UserVO, ContactViewHolder> {

    public CustomAdapter(DatabaseReference reference, String uid){
        super(UserVO.class,
                R.layout.item_contact,
                ContactViewHolder.class,
                reference.child(FIREBASE_USER_GLOBAL_LIST).orderByChild("email"));
    }
Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
Ricardo
  • 7,921
  • 14
  • 64
  • 111

1 Answers1

1

Unfortunately Firebase doesn't provide a method to exclude values in a query, only include (using equalTo()). It is possible to detect the absence of a property though.

Grimthorr
  • 6,856
  • 5
  • 41
  • 53
  • According to this blog there is a solution for not equal queries => https://firebase.googleblog.com/2020/09/cloud-firestore-not-equal-queries.html – Tonnie Oct 13 '20 at 05:37