Question: In collection\_select I need pass following arguments. Total 7, but method accept max 6, how me join? 

```
<%= f.collection_select :skill_list, Project.tag_counts_on(:skills).order(:name), :id, :name, {}, {multiple: true}, validate: true, class: 'form-control' %> 

```

Answer: 
Try using this syntax

```
<%= f.select :skill_list, options_from_collection_for_select(Project.tag_counts_on(:skills).order(:name), "id", "name"), {},:multiple=> true,:validate=> true,:class=> 'form-control' %> 

```
> 
> wrong number of arguments (given 7, expected 4..6)
> 
> 
> 

The problem is the way you are passing the arguments to the `collection_select` is wrong.

> 
> collection\_select(object, method, collection, value\_method,
>  text\_method, options = {}, html\_options = {}
> 
> 
> 

`multiple: true` and `validate :true` should be in place of `options = {}` and the `class: 'form-control'` should go into `html_options = {}`. The below should work

```
<%= f.collection_select :skill_list, Project.tag_counts_on(:skills).order(:name), :id, :name, {multiple: true, validate: true}, class: 'form-control' %> 

```