Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can you add setWhere function ? #111

Open
hunteryun opened this issue Oct 20, 2019 · 0 comments
Open

Can you add setWhere function ? #111

hunteryun opened this issue Oct 20, 2019 · 0 comments

Comments

@hunteryun
Copy link

hunteryun commented Oct 20, 2019

sorry, my English is poor, and I'm not sure if I knew enough before I asked.

I have a need like this :

`
$v = explode(',', $filter['value']);

$where = $query->where()->subWhere("OR");

foreach ($v as $item) {

$where->equals($op_field, $item);

}

$query = $query->setWhere($where);

`
so if have a setWhere function , it will very easy :

in NilPortugues\Sql\QueryBuilder\Manipulation\AbstractBaseQuery file add this :

`
/**
* @return $this
*/
public function setWhere(Where $where)
{
$this->where = $where;

    return $this;
}

`

Thanks for your great project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant