Query Error on Physical Exam form when diagnosis is used for a component of the physical exam

Situation
Editing a previously saved physical exam form of an encounter. Edited the comment for the GEN system that had a diagnosis (dropdown) previously selected. Error message (below) appeared. Opened the encounter again. Changed from the E46 diagnosis drop-down pick to blank, i.e., no diagnosis. Saved. Then changed the diagnosis for the GEN system back to E46 and saved without further issues. I am not sure if this is reproducible or not. I will attempt to reproduce the issue.

OpenEMR Version
I’m using OpenEMR version 5.0.1(7)

Browser:
I’m using: Firefox

Operating System
I’m using: Amazon AWS (Ubuntu Linux EXPRESS instance)

Error Message
Query Error

ERROR: insert failed: INSERT INTO form_physical_exam ( forms_id, line_id, wnl, abn, diagnosis, comments ) VALUES ( β€˜10567’, β€˜PSYOR’, β€˜0’, β€˜1’, β€˜β€™, β€˜AOx0. Did not know name, place, wife’s name, whether he was married or not, year, month, or time of day.’ )

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 β€˜s name, whether he was married or not, year, month, or time of day.’ )’ at line 1

/var/www/localhost/htdocs/openemr/interface/forms/physical_exam/new.php at 107:sqlInsert

looks like there is something strange happening in the display of the dx box

1 Like