Mine latest sql