saintsystems / odata-client-php

OData Client Library for PHP
MIT License
142 stars 101 forks source link

$count needs to be $count=true #91

Closed cooperRjp closed 2 years ago

cooperRjp commented 3 years ago

The $count in the api which i'm querying needs to be set to $count=true, is there a way to do so?

tavy315 commented 3 years ago

@cooperRjp if you take a look at oData's URI convensions or Addressing the Count of a Collection, seems that $count doesn't need anything else.

Also, keep in mind that $count can be used in the path, but also in query as $count=true.

I think the second method is also implemented, so you can probably try the totalCount() method instead of count().

Hope this information helps.