Right, every _share_ purchased is also a share sold (in principle), but that price will not usually be the same price that the current seller originally purchased the share at themselves. As a result, you can have inflow/outflows in dollar amounts. For individuals stocks, with increasing/decreasing market caps, but of course there can be more money in the market overall.