Title: NextGEN gallery voting &#8211; SQL syntax error
Last modified: August 21, 2016

---

# NextGEN gallery voting – SQL syntax error

 *  [pawelo](https://wordpress.org/support/users/pawelo/)
 * (@pawelo)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/nextgen-gallery-voting-sql-syntax-error/)
 * After install the NextGEN gallery voting plugin i get SQL syntax error on my 
   page:
 * WordPress database error: [You have an error in your SQL syntax; check the manual
   that corresponds to your MySQL server version for the right syntax to use near‘)
   AND criteria_id = ‘0’ AND ip = ‘xx.xx.xxx.xx’ ORDER BY dateadded DESC’ at line
   1]
    SELECT * FROM wp_nggv_votes WHERE pid IN () AND criteria_id = ‘0’ AND ip 
   = ‘xx.xx.xxx.xx’ ORDER BY dateadded DESC
 * I also have checked “Only allow 1 vote per person for this gallery” in gallery
   settings.
 * It seems like the function $picturelist = nggdb::get_gallery($image->gid); always
   return empty array in ngg-voting.php file.
 * Anybody knows this issue?

The topic ‘NextGEN gallery voting – SQL syntax error’ is closed to new replies.

 * 0 replies
 * 1 participant
 * Last reply from: [pawelo](https://wordpress.org/support/users/pawelo/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/nextgen-gallery-voting-sql-syntax-error/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
