# I am getting error on first use of OpenEMR

**URL:** <https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064>\
**Category:** Support\
**Created:** [August 23, 2020, 7:18pm UTC](https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064 "2020-08-23T19:18:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Salvador](https://community.open-emr.org/letter_avatar_proxy/v4/letter/s/4da419/32.png) [@Salvador](https://community.open-emr.org/u/Salvador)\
**Post date:** [August 23, 2020, 7:18pm UTC](https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064/1 "2020-08-23T19:18:33Z")

</div>

**Situation**  
It says: Only variables should be passed by reference in C:\xampp\htdocs\openemr\src\Menu\MainMenuRole.php on line 67

It is giving me this error after login and many errors like this: **Notice** : Constant REPEAT\_EVERY\_DAY already defined in **C:\xampp\htdocs\openemr\interface\main\calendar\modules\PostCalendar\common.api.php** on line **54**

**OpenEMR Version**  
I’m using OpenEMR version 5.0.2

**Browser** :  
I’m using: Chrome

**Operating System**  
I’m using: Windowa 10, 64bit

---

<div class="post-metadata">

**Author:** ![visolveemr](https://community.open-emr.org/user_avatar/community.open-emr.org/visolveemr/32/10974_2.png) [@visolveemr](https://community.open-emr.org/u/visolveemr)\
**Post date:** [August 26, 2020, 12:46pm UTC](https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064/2 "2020-08-26T12:46:03Z")

</div>

@Salvador,

Please check whether you have the following configuration in your php.ini file,

[https://community.open-emr.org/t/i-need-help-getting-a-lot-of-errors-notice-undefined-index-state-in-c-xampp-htdocs-openemr-setup-php-on-line-14/3267](https://www.google.com/url?q=https://community.open-emr.org/t/i-need-help-getting-a-lot-of-errors-notice-undefined-index-state-in-c-xampp-htdocs-openemr-setup-php-on-line-14/3267&sa=D&source=hangouts&ust=1598527126090000&usg=AFQjCNGz-qjWEW8VKnmeCCL9Hx95EEbQAQ)

Thanks,  
[ViSolve](http://forum.visolve.com)

---

<div class="post-metadata">

**Author:** ![Prem\_HL7](https://community.open-emr.org/user_avatar/community.open-emr.org/prem_hl7/32/14861_2.png) [@Prem\_HL7](https://community.open-emr.org/u/Prem_HL7)\
**Post date:** [August 26, 2020, 3:31pm UTC](https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064/3 "2020-08-26T15:31:23Z")

</div>

Open the XAMPP control panel -\> Config -\> open php.ini file -\> find for error reporting (hit enter twice).  
Place the code as  
“error reporting =E\_COMPILE\_ERROR|E\_RECOVERABLE\_ERROR|E\_ERROR|E\_CORE\_ERROR”  
This can clear your error.

---

<div class="post-metadata">

**Author:** ![Dr\_Ravindra\_Patil](https://community.open-emr.org/user_avatar/community.open-emr.org/dr_ravindra_patil/32/17620_2.png) [@Dr\_Ravindra\_Patil](https://community.open-emr.org/u/Dr_Ravindra_Patil)\
**Post date:** [June 27, 2024, 9:07pm UTC](https://community.open-emr.org/t/i-am-getting-error-on-first-use-of-openemr/15064/4 "2024-06-27T21:07:36Z")

</div>

SQL Statement failed on preparation: SELECT \* FROM lang\_definitions JOIN lang\_constants ON lang\_definitions.cons\_id = lang\_constants.cons\_id WHERE lang\_id=? AND constant\_name = ? LIMIT 1’  
SQL Statement failed on preparation: SELECT \* FRO
