1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[feature/sphinx-fulltext-search] use Update in sphinx query

Instead of REPLACE use UPDATE since pgsql does not support REPLACE.
A row is inserted at time of creating table so REPLACE is no longer
needed.

PHPBB3-10946
This commit is contained in:
Dhruv
2012-07-12 17:22:03 +05:30
parent b81941a997
commit 81959927e5
2 changed files with 11 additions and 4 deletions

View File

@@ -7,7 +7,7 @@ source source_phpbb_{SPHINX_ID}_main
sql_db = db_name
sql_port = 3306 #optional, default is 3306
sql_query_pre = SET NAMES 'utf8'
sql_query_pre = REPLACE INTO phpbb_sphinx SELECT 1, MAX(post_id) FROM phpbb_posts
sql_query_pre = UPDATE phpbb_sphinx SET max_doc_id = MAX(post_id) WHERE counter_id = 1
sql_query_range = SELECT MIN(post_id), MAX(post_id) FROM phpbb_posts
sql_range_step = 5000
sql_query = SELECT
@@ -27,7 +27,7 @@ source source_phpbb_{SPHINX_ID}_main
p.post_subject,
\
p.post_subject as title,
\
\
p.post_text as data,
\
t.topic_last_post_time,