Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Resolved
-
3.1.2
-
None
-
None
-
PHP 5.5.18, PostgreSQL 9.3.5 on x86_64-redhat-linux-gnu (Fedora 20, 64 bit), Firefox 33.1
Description
Entering a search term of "test test*" will crash phpBB with a general error.
General Error
SQL ERROR [ postgres ]
ERROR: invalid input syntax for integer: "w0.word_id" LINE 1: ... (w0.word_text LIKE 'test%') WHERE m0.word_id IN ('w0.word_i... ^ []
SQL
SELECT COUNT(DISTINCT p.post_id) AS total_results FROM search_wordmatch m0 LEFT JOIN posts p ON (m0.post_id = p.post_id) LEFT JOIN search_wordlist w0 ON (w0.word_text LIKE 'test%') WHERE m0.word_id IN ('w0.word_id', 287726) AND (p.post_visibility = 1 OR p.forum_id IN (1, 2, 3, 4, 5, 6, 7, 9, 10, 11, 14, 15))
BACKTRACE
FILE: (not given by php)
LINE: (not given by php)
CALL: msg_handler()
FILE: [ROOT]/phpbb/db/driver/driver.php
LINE: 855
CALL: trigger_error()
FILE: [ROOT]/phpbb/db/driver/postgres.php
LINE: 191
CALL: phpbb\db\driver\driver->sql_error()
FILE: [ROOT]/phpbb/db/driver/factory.php
LINE: 329
CALL: phpbb\db\driver\postgres->sql_query()
FILE: [ROOT]/phpbb/search/fulltext_native.php
LINE: 784
CALL: phpbb\db\driver\factory->sql_query()
FILE: [ROOT]/search.php
LINE: 525
CALL: phpbb\search\fulltext_native->keyword_search()
=========================================
Entering a search term "test test" with no wildcard (joker) character works as expected.
This bug is a continuation of the discussion from The operator for partial matches does not work .
I am using phpBB Native Fulltext search, postgreSQL.