Testing select function