get nodes from DB