I was searching the net to find some info about it(in the title), but I found not much(neither in my language or in English). I would be really happy if somebody could explain it to me. The questions really are choosing index for the inner table in join and choosing index for the outer table in join.
The optimiser chooses the indexes from those available on the tables. If you are joining on the "outer" table by column X then it may choose to use an index defined on column X. For the "inner" table (which I assume means driving table?), it may use an index suitable for filtering conditions, e.g. if you specified "WHERE inner.col1 = 123" then it may use an index on col1.