mirror of
				https://gitlab.com/Alamantus/Readlebee.git
				synced 2025-10-31 16:36:48 +01:00 
			
		
		
		
	PGSQL requires group by id for book search
This commit is contained in:
		
							parent
							
								
									97247373a9
								
							
						
					
					
						commit
						0b9e9d00fa
					
				
					 1 changed files with 6 additions and 0 deletions
				
			
		|  | @ -48,6 +48,12 @@ class SearchController { | |||
|         [fn('AVG', col('Ratings.rating')), 'averageRating'], | ||||
|       ], | ||||
|       order: [[col('totalInteractions'), 'DESC']], | ||||
|       group: [ | ||||
|         col('BookReference.id'), | ||||
|         col('Interactions.id'), | ||||
|         col('Reviews.id'), | ||||
|         col('Ratings.id'), | ||||
|       ], | ||||
|     }; | ||||
|   } | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue