I found that I can't use variadic parameter list for in clause with prepare statment.
Here's what I've tried (but failed).
In a simple statement I can do:
$stmt = 'SELECT * FROM some_table WHERE id in ?';
$inSet = Type::set(Type::varchar())->create('a','b','c');
$session->execute($stmt, ['arguments'=>[$inSet]];
But In a prepare statment I'll get:
PHP Fatal error: Uncaught Cassandra\Exception\InvalidArgumentException: Invalid value type
I've also tried to use an array:
$stmt = $session->prepare('SELECT * FROM some_table WHERE id in ?');
$inArr = ['a','b','c'];
$session->execute($stmt, ['arguments'=>[$inArr]]);
But get NOTHING!!!???? Without any error code nor result. Same when I used simple statment.
Accroding to https://issues.apache.org/jira/browse/CASSANDRA-4210
This feature should be supported in 2.0.1
I'm using 2.7.0 C/C++ driver
1.3.2 php7.0-cassandra-driver
So I think this could be a bug?
Thank you
Best regard
Lin