Error with adding a list item to LBF List box w/add field

Situation
I am not able to add an item to LBF List box w/add field. Some times I get pop up with Authentication Error. I did check the demo site and they are working fine. My work around is adding the item directly to the list but I was hoping I can find a fix to this

OpenEMR Version
I’m using OpenEMR version 7.0.2 patch 2

Browser:
I’m using: Chrome

Operating System
I’m using: Debian 12

Search
Did you search the forum for similar questions?
Yes, there was one similar issue in Jul 2019 but no answer provided

Logs
Did you check the logs? Yes
Was there anything pertinent in them? Yes

[12/Nov/2024:12:26:09 -0500] "GET /library/ajax/addlistitem.php?csrf_token_form=1111111111111111111&listid=country&newitem=random&newitem_abbr=random HTTP/1.1" 200 725 "https://openemr/interface/patient_file/summary/demographics_full.php" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36"
[Tue Nov 12 17:43:47.506274 2024] [php:notice] [pid 146023:tid 146023] SQL Error with statement:query failed: SELECT * FROM list_options WHERE  list_id= ? AND option_id = ?AND activity = 1--You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '?AND activity = 1' at line 1==>/var/www/openemr/library/ajax/addlistitem.php at 52:sqlQuery, referer: https://openemr/interface/patient_file/summary/demographics_full.php
[Tue Nov 12 17:43:55.621254 2024] [php:notice] [pid 146019:tid 146019] [client 107.143.107.236:8137] OpenEMR CSRF token authentication error, referer: https://emr.carepointinfusion.com/interface/patient_file/summary/demographics_full.php

You can also turn on User Debugging under Administration->Globals->Logging User Debugging Options=>All

Thanks for the backups.

I rolled back to a previous backup, and everything’s working fine now. :smiley:

1 Like