Implementing server side of selects