- 论坛徽章:
- 0
|
错误信息:
indexing index 'wp_main'...
ERROR: index 'wp_main': column number 6 has no name.
total 0 docs, 0 bytes
total 0.001 sec, 0 bytes/sec, 0.00 docs/sec
我的配置如下:
sql_port = 3306
sql_sock = /tmp/mysql.sock
sql_query_pre = SET NAMES UTF8
sql_query_pre = CREATE TABLE IF NOT EXISTS cms_sph_counter ( counter_id INTEGER PRIMARY KEY NOT NULL,max_doc_id INTEGER NOT NULL)
sql_query_pre = REPLACE INTO cms_sph_counter SELECT 1, MAX(id) FROM app
sql_query = SELECT id, id as pid, title, UNIX_TIMESTAMP(updated) AS updated, UNIX_TIMESTAMP(releaseDate) AS releaseDate,shortDescription, \
CRC32(language) AS language, langsort, price*100 as price, history_price*100 as history_price, comment_count, down_count, is_free, \
dig_up_count, averageAppRating*10 as averageAppRating , is_off, UNIX_TIMESTAMP(change_price_time) AS change_price_time , is_zh_cn, is_en_us, is_zh_hk,keywords \
FROM app \
WHERE id>=$start and id<=$end
#sql_query第一列id需为整数
#title、content作为字符串/文本字段,被全文索引
sql_query_range = SELECT (SELECT MIN(id) FROM app),max_doc_id FROM cms_sph_counter WHERE counter_id=1
sql_range_step = 4096
sql_attr_uint = pid #从SQL读取到的值必须为整数
sql_attr_uint = language
sql_attr_uint = price
sql_attr_uint = history_price
sql_attr_uint = langsort
sql_attr_uint = comment_count
sql_attr_uint = down_count
sql_attr_uint = dig_up_count
sql_attr_uint = averageAppRating
sql_attr_uint = is_free
sql_attr_uint = is_off
sql_attr_uint = is_zh_cn
sql_attr_uint = is_en_us
sql_attr_uint = is_zh_hk
sql_attr_multi = uint tag_id from ranged-query; \
SELECT app_id, tag_id FROM cms_tag_relations WHERE app_id>=$start and app_id<=$end; \
SELECT (SELECT MIN(id) FROM app),max_doc_id FROM cms_sph_counter WHERE counter_id=1
sql_attr_multi = uint license_id from ranged-query; \
SELECT app_id, license_id FROM app_offers WHERE app_id>=$start AND app_id<=$end; \
SELECT (SELECT MIN(id) FROM app), max_doc_id FROM cms_sph_counter WHERE counter_id=1
sql_attr_timestamp = updated #从SQL读取到的值必须为整数,作为时间属性
sql_attr_timestamp = releaseDate
sql_attr_timestamp = change_price_time
sql_query_info_pre = SET NAMES utf8 #命令行查询时,设置正确的字符集
sql_query_info = SELECT * FROM app WHERE id=$id #命令行查询时,从数据库读取原始数据信息 |
|