Added select function