Materials and objects

i’ve some problems understanding how material association works in Blender. Basically you can assign a material to an object. An object, as much as i know is a mesh that can be editable in Edit mode. The thing i cant understand is if i take 2 objects with different materials/mapping/textures and make Join Objects they form a unique object but the materials remain setted like when the 2 meshes were separated. Another example is the pics in the Blender documentation about Boolean operations
As can you see in the last image the object created from the intersections of 2 meshes have the 2 materials in it. I’ve tried the same thing with materials with and without UV and the result is the same.
So an object can have multiple materials in it? Is this possible? Think about a room with its walls. If need to set a unique texture to each wall i need to create each wall separately as single object or i can create a cube in Edit mode (i think) selecting the wall and assign a material to it? In this second case i cant understand how i can know which materials are used for this object and if i want to select/know what polies are of that material how i can do this?

Excuse me for this misunderstandings, but i cant find much explanation of this in the documentation

A mesh can have up to 16 different materials. Each face in a mesh however, can only have one material associated with it. See the documentation for how to assign faces or groups of faces to different materials.


Thank you,
in another example, if i’ve a rectangular room where 2 walls are x3 the other ones and i need to set the same texture on all 4, i must change scaling of the first 2. In this case i need to create 2 materials with same texture but different settings or there’s a simple way to have this?