PHP SDK: Class 'CouchbaseNq1lQuery' not found

Hi I’m getting the following error message:

Fatal error: Class ‘CouchbaseNq1lQuery’ not found in CouchbaseNative on line 792

Below my code:

$cluster = new \CouchbaseCluster(‘’);
$cluster = $cluster->openBucket(‘bucket’);

$query = \CouchbaseN1qlQuery::fromString(“SELECT * FROM bucket”);

Everything is running correctly and I’ve installed the latest version via PECL. Any ideas?


Hey willewolle,

I’ve found the source of this issue and the fix will be integrated with our next release (releases occur on the first Tuesday of each month).

Cheers, Brett

Hey willewolle,

Unfortunately, the release that went out today contained a typo that continues to cause the CouchbaseN1qlQuery class to miss-behave. A fix is however available on GitHub if you wish to attempt to use that.

Cheers, Brett

Hi Brett,

thanks for letting me know. I’ll have a go later on today :slight_smile: