Can not add a new post

This area is for the discussion of what's new, what's on your mind, and general photographic topics. A place to meet, make comments on this site, and get the latest community news.

Moderators: rjlittlefield, ChrisR, Chris S., Pau

iHasan
Posts: 9
Joined: Tue Oct 31, 2017 10:31 pm

Can not add a new post

Post by iHasan »

I get this error
-------------------------------------
Could not insert new word matches

DEBUG MODE

SQL Error : 1271 Illegal mix of collations for operation ' IN '

INSERT INTO phpbb_search_wordmatch (post_id, word_id, title_match) SELECT 224033, word_id, 0 FROM phpbb_search_wordlist WHERE word_text IN ('first', 'attempt', 'using', 'sony', 'a7r', 'iii', '?lens', 'amscope', 'objective', 'lens', 'flash', 'kuangren', 'twins', '?na', '25', 'number', 'pictures', 'step', 'size', 'um', 'stacked', 'wemacro', 'affinity', 'photo')

Line : 251
File : functions_search.php
-----------------------

Any idea why?

ChrisR
Site Admin
Posts: 8662
Joined: Sat Mar 14, 2009 3:58 am
Location: Near London, UK

Post by ChrisR »

This does happen sometimes,. Usually there's a strange character string in a link, or one of the accented text characters causes a problem.
It's not at "our" level, it's back at the server.
For links a workaround is to use a Link Shortener.
Chris R

rjlittlefield
Site Admin
Posts: 23543
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

The place to look for problems is where that "?" appears in the list of words. In this case it's at '?lens' and '?na'.

The underlying issue is that for historical reasons the forum database uses a character set named "latin1" (description: https://en.wikipedia.org/wiki/ISO/IEC_8859-1). latin1 is only a subset of Unicode. If a post uses any Unicode characters that are not contained in latin1, then the post will preview OK but produce the message about "Illegal mix of collations" when it gets Submit'ed and stored in the database.

It's a very annoying problem that was caused by a change in the PHP specification several years ago. If you're curious, see the 3-page discussion at http://www.photomacrography.net/forum/v ... hp?t=25154 .

--Rik

Post Reply Previous topicNext topic