Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
71 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1 @@ | |||
a:1:{i:0;a:3:{i:0;a:3:{s:8:"sphinxql";s:58:"select id from test1 where id in (1,13) and gid not in (1)";s:10:"total_rows";i:2;s:4:"rows";a:2:{i:0;a:1:{s:2:"id";s:1:"1";}i:1;a:1:{s:2:"id";s:2:"13";}}}i:1;a:3:{s:8:"sphinxql";s:74:"select id from test1 where id in (1,13) and gid not in (1) force index(id)";s:10:"total_rows";i:2;s:4:"rows";a:2:{i:0;a:1:{s:2:"id";s:1:"1";}i:1;a:1:{s:2:"id";s:2:"13";}}}i:2;a:3:{s:8:"sphinxql";s:75:"select id from test1 where id in (1,13) and gid not in (1) ignore index(id)";s:10:"total_rows";i:2;s:4:"rows";a:2:{i:0;a:1:{s:2:"id";s:1:"1";}i:1;a:1:{s:2:"id";s:2:"13";}}}}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,59 @@ | |||
<?xml version="1.0" encoding="utf-8"?> | |||
<test> | |||
|
|||
<name>id attr index</name> | |||
|
|||
<config> | |||
indexer | |||
{ | |||
mem_limit = 16M | |||
} | |||
|
|||
searchd | |||
{ | |||
<searchd_settings/> | |||
} | |||
|
|||
source test1 | |||
{ | |||
type = mysql | |||
<sql_settings/> | |||
sql_query = select id, gid, title from test_table | |||
sql_attr_uint = gid | |||
sql_field_string = title | |||
} | |||
|
|||
index test1 | |||
{ | |||
source = test1 | |||
path = <data_path/>/test1 | |||
} | |||
</config> | |||
|
|||
<db_create> | |||
create table test_table | |||
( | |||
id int not null, | |||
gid int not null, | |||
title varchar(255) not null | |||
); | |||
</db_create> | |||
<db_drop>drop table if exists test_table;</db_drop> | |||
|
|||
<db_insert> | |||
insert into test_table values | |||
( 1, 11, 'test' ), | |||
( 2, 12, 'test' ), | |||
( 3, 13, 'test' ), | |||
( 11, 21,'test' ), | |||
( 12, 22, 'test' ), | |||
( 13, 23, 'test' ) | |||
</db_insert> | |||
|
|||
<sphqueries> | |||
<sphinxql>select id from test1 where id in (1,13) and gid not in (1)</sphinxql> | |||
<sphinxql>select id from test1 where id in (1,13) and gid not in (1) force index(id)</sphinxql> | |||
<sphinxql>select id from test1 where id in (1,13) and gid not in (1) ignore index(id)</sphinxql> | |||
</sphqueries> | |||
|
|||
</test> |