When I join a layer with another layer all the attributes are correctly displayed in the first layer.
However when I use the Query builder (Layer - Query) and then use Zoom to layer, nothing is displayed.
I have added a vector layer with attribute values from Excel and joined it with another layer consisting of polygons. The polygon layer then displays all the attributes in its table from the Excel imported layer. When I want to view only selected polygons using the Layer > Query using the joined attribute values and use Zoom to Extent nothing happens.
Rule-based styling seems to be the answer.