Here is a piece of code I\'m using now:
<%= f.select :project_id, @project_select %>
How to modify it to make its default value equal
if params[:pid] is a string, which if it came from a form, it is, you'll probably need to use
params[:pid].to_i
for the correct item to be selected in the select list