Skip to content

Basic Query test fails #194

@yazer79

Description

@yazer79

Hi,
I am using composer installation of "foolz/sphinxql-query-builder" and a sphinx index with test result. I am trying to use this simple test php script, but I get an error:
"Fatal error: Uncaught Error: Call to undefined method Foolz\SphinxQL\SphinxQL::create()"
Any suggestions?
Windows 10 - composer 2 - PHP 7.1 - sphinxsearch 3.1.1

require_once __DIR__ ."/../vendor/autoload.php";

use Foolz\SphinxQL\SphinxQL;
use Foolz\SphinxQL\Drivers\Mysqli\Connection;
 
$conn = new Connection();
$conn->setParams(array('host' => 'localhost', 'port' => 9306));

$query = SphinxQL::create($conn)
->select('*')
->from('test_index')
->match('test');

$result = $query->execute();
$results = $result->fetchAllAssoc();
print_r($results);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions