Project

General

Profile

Bug #86859

Updated by Sybille Peters over 2 years ago

Searching with indexed_search for a term (word) with a large number of results throws exception: 

 <pre><code class="text"> 
 An exception occurred while executing  
 'SELECT `ISEC`.*, `IP`.*, MAX(`IR`.`flags`) AS `order_val1`, SUM(`IR`.`freq`) AS `order_val2` FROM `index_phash` `IP`, `index_section` `ISEC`, `index_words` `IW`, `index_rel` `IR`  
 WHERE (`IP`.`phash` IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 
 ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,  
 ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,  

 .... etc.  

 )) AND (`IW`.`wid` = `IR`.`wid`) AND (`ISEC`.`phash` = `IR`.`phash`) AND (`IW`.`baseword` LIKE '%institut%') GROUP BY `IP`.`phash`, `ISEC`.`phash`, `ISEC`.`phash_t3`, `ISEC`.`rl0`, `ISEC`.`rl1`, `ISEC`.`rl2`, `ISEC`.`page_id`, `ISEC`.`uniqid`, `IP`.`phash_grouping`, `IP`.`data_filename`, `IP`.`data_page_id`, `IP`.`data_page_reg1`, `IP`.`data_page_type`, `IP`.`data_page_mp`, `IP`.`gr_list`, `IP`.`item_type`, `IP`.`item_title`, `IP`.`item_description`, `IP`.`item_mtime`, `IP`.`tstamp`, `IP`.`item_size`, `IP`.`contentHash`, `IP`.`crdate`, `IP`.`parsetime`, `IP`.`sys_language_uid`, `IP`.`item_crdate`, `IP`.`cHashParams`, `IP`.`externalUrl`, `IP`.`recordUid`, `IP`.`freeIndexUid`, `IP`.`freeIndexSetId` ORDER BY `order_val1` DESC, `order_val2` DESC' with params [754, 2499,  
 6477, 11827, 12442, 1  

 ... etc.  

 Prepared statement contains too many placeholders  

 </code></pre> 


 h2. System environment 

 TYPO3 version 8.7.20 

 h2. Steps to reproduce 

 # Get installation with a large number of pages / words.  
 # Search for a term that is common on those page.  

 (I could probably test to get the exact number, but I assume, someone knows this without tedious tests).  


 h2. Exception 

 Exception is thrown in _IndexSearchRepository::execFinalQuery_ when _$queryBuilder->execute_ is called. There may be other occurances. 

 Best to generally search for *expr()->in(* 

  

 h2. Comment 


 As indexed_search is not suited for large installations and this may not get fixed, I think at least the "docs":https://docs.typo3.org/typo3cms/extensions/indexed_search/ should name the restrictions specifically, e.g. what exactly are the limits, e.g. number of pages, number of words, if possible.   

Back