How many shops can you have? Many. As long as you have customers and suppliers. Same for the number of stock exchanges. You can run a profitable stock exchange as long as you have companies trying to sell their shares through you and traders trying to buy the shares. We still have 21 although most are very small or irrelevant.
BSE is the older company dating back to 1875 and by 1992 the government found that it was slacking. BSE had no competition back then and its brokers were a closed group of merchants. There was very little technology, transparency or openness. That was not good for country that was just opening up.
Source: Quora answer by Balaji Viswanathan