❌ An unknown error occurred while starting the exam.
Relevant Script
/start_exam.php
Failing Action
Single INSERT query into the student_exams table.
User/Batch IDs
The logged-in student is User ID 11. The exam batch is Batch ID 2.
Objective
Crucial: I need the exact error code and message from the raw MySQL error log for my database (if0_40410928_cbtplatform).
The application is failing on the exam start process. I have eliminated all possible PHP code errors, removed all transaction wrappers, and confirmed all data integrity on my end.
The failure occurs when the PHP script attempts to execute this single-row query:
The profile for user_id = 11 is complete and marked as is_profile_complete = 1.
The batch batch_id = 2 exists and is active.
There is no disk space usage issue.
The server is intercepting the actual database error and replacing it with the generic message. Please check the server logs for the specific ERROR or WARNING related to this database write operation so I can finally resolve this issue.
After this, please share the error you see printed on-screen when you perform your actions, and we can try to help you out.
Also, please refrain from using Artificial Intelligence to write your posts. If you need a translator, please use something like Google Translate or Disroot Translate. AI likes to add snake oil to posts.
This is true in the sense that “the server” refers to your own PHP code. Your code is swallowing the actual database error message and returning the generic error. Our hosting is not telling you that the exam could not be started, our hosting isn’t aware of “business” entities like exams.
Our MySQL databases and our PHP installations (including both the PDO and MySQLi extensions) work exactly like you can expect them to work, and any database error messages are provided to your software in all the regular ways as described in the PHP documentation.
If you would like to obtain the real database error message, you should check that with the developer of the website. And if you built it yourself, then you should know. Maybe there is a debug mode that display the error, or maybe you need to add some debug statement to your code to obtain the error message.
Finally, please be aware that this is a community forum. Most people here are just other forum members without special permissions. Most people here can’t see your code, your database, your queries, or any logs. That means that for the most part, all we can do is to help guide you in solving the issue yourself, as opposed to us solving the issue for you.