Streamlined the retrieval of the last largest revision number