i dont understand the point in adding exchange rate to each block as it will be different on the next block. maybe op is confused on the notion of supply and demand and exchange rates from fiat to bitcoin. no one sets these and the market would not use the "block rate" rather would still find its own rate.
Exactly! it will be different on the next block. That is the point. It is not directive issued by someone. It is just "official" ascertaining or the market price snapshot.
What we need it for? Firstly it is convenience. Every single merchant don't have to analyse and calculate average price from different major exchanges. Merchant don't have to trust any third party website doing this work for him. As soon as this value is already average for the market and confirmed along with the block it may be well trusted.
Secondly there are two side effects which I found very nice. We say "market price". Who forms that market price? Stock exchange players. It means "Wall Street" of the Bitcoin community. Doesn't it look familiar and dull? If we allow any peer offer its price it is going to be more democratic (and fun). If you are fat wallet holder fine bully the price. If you are bitcoin-poor lower it hoping to buy more. Obviously all nonsense offers will be just dumped.
Another side effect is that in order to qualify peer's offer algorithm have to compare it with the last confirmed rate. Therefor huge sudden drops or raises due to technical problems in exchanges will be smoother and won't raise panic. It makes Bitcoin more stable.