Skip to content

Where clause with array param #58

@lalop

Description

@lalop

I think that can be a good thing to permit make one single call to the where method for multiple conditions. Something like that :

public function where($column_name, $value = null) {
    if(is_array($column_name)){
        $self = $this;
        foreach($column_name as $key=>$value){
            $self = $self->where_equal($key, $value);
        }
        return $self;
    } else {
        return $this->where_equal($column_name, $value);
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions