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

Count function doesn't work #126

Open
milito-78 opened this issue Jun 14, 2022 · 0 comments
Open

Count function doesn't work #126

milito-78 opened this issue Jun 14, 2022 · 0 comments

Comments

@milito-78
Copy link

Hi
I need count query, but I can't use in write function because ColumnQuery class doesn't implement from QueryInterface.
And count function returned ColumnQuery instance.

`
$query = $builder->select()
->setTable('users')
->count()

echo $builder->write($query);
`

Error :
ilPortugues\Sql\QueryBuilder\Builder\GenericBuilder::write(): Argument #1 ($query) must be of type NilPortugues\Sql\QueryBuilder\Manipulation\QueryInterface, NilPortugues\Sql\QueryBuilder\Manipulation\ColumnQuery given

How can I resolve this?

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