I'm using the firestore where() method to test the equality of a nested field against another value. The nested field is in the document structure: Apartments/Apartment/property/address/locality_short
Here is how I am currently doing it (in the code below) but it's not returning any documents: //There import import { AngularFirestore} from 'angularfire2/firestore';
//The injection constructor(private afs: AngularFirestore){}
//The method which retrieves apartments based on whether //apartment.property.address.locality_short == search_object.locality_short
search(search_obj: Search):Observable{
return this.afs.collection('/Apartments', ref =>
ref.where(property,address,locality_short
, '==',
'search_obj.Address.locality_short')).valueChanges()
}