update query slector all implementation to use join