Forgive me if this question is naive. From what I understand about market orders, they are filled at the best available market price, and thus jump in front of limit orders in the same direction. This is all well and good in a market with high liquidity (ie when there's sure to be lots of competing orders) but what about the scenario where, at market open, Bob sends in a bid for 10 shares of asset1 where Paul sends in an ask for 10 shares of asset1? Is there some kind of pricing information that is saved from day to day by the market? To be specific, I think this scenario would only take place in an order-driven market without a market maker. In the case of an exchange with a market maker, how are problems like this one at market open accounted for? Does the MM save the last ask and bid price at which an order has been filled, and start the process at these prices for the next market day?


