0
我在狮身人面像SE是新的PHP狮身人面像客户端选择所有最新的索引数据。我有两个查询,我努力尝试,但失败了。从狮身人面像搜索
一)我试图从狮身人面像一些结果就像是在SQL(SELECT * FROM table ORDER BY date DESC
)。 例子:
$results = $client->Query('*', 'posts');
sphinx.conf中的文件我已经在指数部分
b)还正在试图对博客评论的索引号加enable_star = 1
,没写的.conf这一点。
的sphinx.conf:
source blog
{
type = mysql
sql_host = localhost
sql_user = root
sql_pass = root
sql_db = myblog
sql_port = 3306 # optional, default is 3306
sql_query = SELECT id, title, content, UNIX_TIMESTAMP(publish_date) AS publish_date, author_id FROM posts
sql_attr_uint = author_id
sql_field_string = title
sql_field_string = content
sql_attr_multi = uint category_id from query; \
SELECT post_id, category_id FROM posts_categories
sql_attr_timestamp = publish_date
sql_query_info = SELECT id, title FROM posts WHERE ID=$id
}
index posts
{
source = blog
path = C:\sphinx\data\blog
docinfo = extern
charset_type = sbcs
}
indexer
{
mem_limit = 32M
}
searchd
{
listen = 9312
log = c:\sphinx\log\searchd.log
query_log = c:\sphinx\log\query.log
max_children = 30
pid_file = c:\sphinx\log\searchd.pid
}
我已经添加了的.conf。 – Flair