1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204
|
<?xml version="1.0" encoding="utf-8"?>
<test>
<name>quorum</name>
<config>
indexer
{
mem_limit = 16M
}
searchd
{
<searchd_settings/>
workers = threads
}
source test1
{
type = mysql
<sql_settings/>
sql_query = SELECT * FROM test_table where document_id in ( 1, 2 )
}
index test
{
source = test1
path = <data_path/>/test
}
index test_crc
{
source = test1
path = <data_path/>/crc
dict = crc
min_prefix_len = 1
}
index test_kw
{
source = test1
path = <data_path/>/kw
dict = keywords
min_prefix_len = 1
}
source test2
{
type = mysql
<sql_settings/>
sql_query = SELECT * FROM test_table where document_id in ( 10, 11 )
}
index crc2
{
source = test2
path = <data_path/>/crc2
dict = crc
min_infix_len = 3
}
index kw2
{
source = test2
path = <data_path/>/kw2
dict = keywords
min_infix_len = 3
}
index rt_infix
{
type = rt
path = <data_path/>/rt-infix
dict = keywords
min_infix_len = 3
rt_field = text
rt_attr_uint = idd
}
source num1
{
type = mysql
<sql_settings/>
sql_query = SELECT 1 id, 11 idd, 'set up 3.51 from data' text
}
index num2t
{
source = num1
path = <data_path/>/num1
charset_table = 0..9, A..Z->a..z, _, a..z
}
index num1t
{
source = num1
path = <data_path/>/num2
charset_table = 0..9, A..Z->a..z, _, a..z, U+2E
}
source test_q1
{
type = mysql
<sql_settings/>
sql_query = SELECT 1 id, 11 idd, "есть и можешь купить набор" text
sql_attr_uint = idd
}
index test_q1
{
source = test_q1
path = <data_path/>/test_q1
charset_table = 0..9, A..Z->a..z, _, ., -, a..z, U+410..U+42F->U+430..U+44F, U+430..U+44F, U+0401->U+0435, U+0451->U+0435
morphology = stem_enru
min_infix_len = 1
index_exact_words = 1
expand_keywords = 1
}
</config>
<db_create>
CREATE TABLE test_table
(
document_id INT NOT NULL,
text VARCHAR(255) NOT NULL
);
</db_create>
<db_drop>
DROP TABLE IF EXISTS test_table;
</db_drop>
<db_insert>
INSERT INTO test_table ( document_id, text ) VALUES
( 1, 'hello world' ),
( 2, 'one two three four five' ),
( 10, 'al all' ),
( 11, 'always' );
</db_insert>
<queries>
<query mode="extended2" index="test">"hello heaven"/1</query>
<query mode="extended2" index="test">"hello from above"/2</query>
<query mode="extended2" index="test">"one two foo bar"/3</query>
<query mode="extended2" index="test">"one two two bar"/3</query>
<query mode="extended2" index="test">"one two two bar"/2</query>
<query mode="extended2" index="test">"two two one three"/3</query>
<query mode="extended2" index="test">"two two one foo"/3</query>
<!--here is going a couple of regresssion tests-->
<query mode="extended2" index="test_crc">"o* t*"/2</query>
<query mode="extended2" index="test_kw">"o* t*"/2</query>
<query mode="extended2" index="test_crc">"h* w* f*"/2</query>
<query mode="extended2" index="test_kw">"h* w* f*"/2</query>
<!--here is going regresssion test-->
<query mode="extended2" index="test_kw">"one t* three four five"</query>
<!--here is going regresssion test-->
<query mode="extended2" index="crc2">al*</query>
<query mode="extended2" index="crc2">alw*</query>
<query mode="extended2" index="kw2">al*</query>
<query mode="extended2" index="kw2">alw*</query>
<query mode="extended2" index="crc2">al* | alw*</query>
<query mode="extended2" index="kw2">al* | alw*</query>
<!-- here is precent quorum test -->
<query mode="extended2" index="test"> "one world"/0.1 </query>
<query mode="extended2" index="test"> "five tree oak one two hive"/0.4 </query>
<query mode="extended2" index="test"> "five tree oak one two hive"/0.59 </query>
<query mode="extended2" index="test"> "five tree oak one two hive"/0.60 </query>
</queries>
<sphqueries>
<!-- here is going regression crash on delete doc from RT with infix -->
<sphinxql>INSERT INTO rt_infix VALUES ( 1, 'dummy word', 11 )</sphinxql>
<sphinxql>delete from rt_infix where id=1</sphinxql>
<!-- regression float at full-text -->
<sphinxql>CALL KEYWORDS ( ' 3.51 ', 'num2t' )</sphinxql>
<sphinxql>CALL KEYWORDS ( ' 3.51 ', 'num1t' )</sphinxql>
<sphinxql>SELECT * FROM num2t WHERE MATCH ( ' 3.51 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num1t WHERE MATCH ( ' 3.51 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num2t WHERE MATCH ( ' 3 51 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num2t WHERE MATCH ( ' "set of 3.51"/0.7 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num1t WHERE MATCH ( ' "set of 3.51"/0.7 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num2t WHERE MATCH ( ' "set of 3 51"/0.7 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<sphinxql>SELECT * FROM num1t WHERE MATCH ( ' "set of 3 51"/0.7 ' )</sphinxql>
<sphinxql>SHOW META</sphinxql>
<!-- regression duplacates from multiple qpos -->
<sphinxql>SELECT id FROM test_q1 WHERE MATCH(' "наборы купить набор"/2 ') ORDER BY ID ASC</sphinxql>
</sphqueries>
</test>
|