Complex sentence: In a very few cases this is due to the termination of the work for which the community was established but in most cases it is due to amalgamation, or the death of the final remaining member of the community.
Split into simpler sentences: In a very few cases this is due to the termination of the work for which the community was established. In most cases it is due to amalgamation, or the death of the final remaining member of the community.