Why does the sentence 'People, who lived in the neighbourhood, were opposed to the building plans' sound funny?
If you are using a relative clause to identify the person or thing you are talking about, you should not separate it from the main clause with a comma.
• The man who lives next door is very helpful.
In the above sentence, the words who lives next door tell us which man is being talked about.
You could only say:
• The man, who lives next door, is very helpful.
If you had already identified the man in some other way, use commas to separate off a relative clause that gives more information, which may be interesting but is not essential if someone is to understand what you are saying, but don't use a comma if the relative clause is essential to the meaning of the sentence.