1 2--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 3eval create table ts ( id bigint unsigned not null, w int not null, q varchar(255) not null, index(q) ) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/*"; 4select * from ts where q='test'; 5drop table ts; 6 7--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 8eval create table ts ( id bigint unsigned not null, w int not null, q varchar(255) not null, index(q) ) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/*"; 9select * from ts where q='test;filter=gid,1;mode=extended'; 10select * from ts where q='test|one;mode=extended'; 11select * from ts where q='test;offset=1;limit=1'; 12--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 13eval alter table ts connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/test1"; 14select id, w from ts where q='one'; 15drop table ts; 16 17--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 18eval create table ts ( id bigint unsigned not null, w int not null, q varchar(255) not null, gid int not null, _sph_count int not null, index(q) ) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/test1"; 19select * from ts; 20select * from ts where q=''; 21select * from ts where q=';groupby=attr:gid'; 22explain select * from ts where q=';groupby=attr:gid'; 23SET @save_optimizer_switch=@@optimizer_switch; 24SET optimizer_switch='index_condition_pushdown=off'; 25explain select * from ts where q=';groupby=attr:gid'; 26SET optimizer_switch=@save_optimizer_switch; 27drop table ts; 28 29# 30# Don't show sphinx error as this is different between sphinx versions 31# show status like "sphinx_error%"; 32 33show status like "sphinx_total%"; 34show status like "sphinx_word%"; 35 36--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 37eval create table ts ( id bigint unsigned not null, w int not null, q varchar(255) not null, index(q) ) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/*"; 38select * from ts where q=';filter=meta.foo_count,100'; 39select * from ts where q='test;filter=meta.sub.int,7'; 40select * from ts where q=';filter=meta.sub.list[0],4'; 41select * from ts where q=';filter=meta.sub.list[1],4'; 42select * from ts where q='test;range=meta.foo_count,100,500'; 43drop table ts; 44 45--echo # 46--echo # MDEV-19205: Sphinx unable to connect using a host name 47--echo # 48 49--replace_result $SPHINXSEARCH_PORT SPHINXSEARCH_PORT 50eval create table ts ( id bigint unsigned not null, w int not null, q varchar(255) not null, index(q) ) engine=sphinx connection="sphinx://localhost:$SPHINXSEARCH_PORT/*"; 51select * from ts where q=';filter=meta.foo_count,100'; 52select * from ts where q='test;filter=meta.sub.int,7'; 53select * from ts where q=';filter=meta.sub.list[0],4'; 54select * from ts where q=';filter=meta.sub.list[1],4'; 55select * from ts where q='test;range=meta.foo_count,100,500'; 56drop table ts; 57