Menu

Invalid SQL error in c_messages phpmychat-plus 1.96

Help
2018-01-12
2018-01-16
  • Claire Stafford

    Claire Stafford - 2018-01-12

    I have just installed rev 1.96 of phpmychat-plus on a Fedora 26 system. After about 30 minutes of activity on the site, I suddenly got the error:
    Database error: Invalid SQL: SELECT type FROM c_messages WHERE room = 'Open Chat Room' ORDER BY m_time DESC LIMIT 1
    MySQL error: ()
    Session halted.

    I deleted the install and database, did it over again, started a chat session and got the same error after just a few posts. Using phpMyAdmin I can give the error causing select command and, other than being warned that the table has no unique column, it works. Here is a dump of the c_messages table:

    type room username latin1 m_time address message pm_read room_from
    1 Open Chat Room SYS enter 0 1515700555 stripslashes(sprintf(L_ENTER_ROM_NOSOUND, "User1"...
    1 Open Chat Room SYS enter 0 1515701032 stripslashes(sprintf(L_ENTER_ROM_NOSOUND, "User2"...
    1 Open Chat Room User2 0 1515701044 geez
    1 Open Chat Room User1 0 1515701047 <IMG SRC="images/smilies/smile1.gif" BORDER=0 ALT=...
    1 Open Chat Room User2 0 1515701057 what a fiasco
    1 Open Chat Room User1 0 1515701060 whaaat?
    1 Open Chat Room User2 0 1515701067 let me bookmark the room
    1 Open Chat Room User1 0 1515701076 fiasco with who?
    1 Open Chat Room User1 0 1515701079 ok
    1 Open Chat Room User2 0 1515701087 testing

     
  • Ciprian Murariu

    Ciprian Murariu - 2018-01-16

    Hi Claire and sorry for the late response.
    I have seen this behaviour on another server just recently. I am still trying to figure out which setting of your MySQL server is causing this - I suppose it's a "stict_mode" enabled issue, but I want to go deeper into how to overcome this.
    If you wanna help me hunt down this bug/error, would you be so kind to send me a private email with a link to your chat, at ciprianmp at yahoo dot com?
    Thank you!
    Ciprian

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.