added prev family query functionality in preparation for the real deal