“The submission was not found in the database” Error
Error: “The submission was not found in the database”
Code: submission-not-found
This error occurs when a submitted form or data entry cannot be found in the database. As a general catch-all, reviewing the corresponding test video often provides more valuable insights into the cause of the failure.
If the message instead says the form did not send anything to the site, the form never left the page. See “The form did not send anything to the site” Error.
If the message says how your site answered
When the form’s request comes back with an error, fails, or gets no answer, the message says so, for example: “The site answered the form with 403 Forbidden (POST /wp-admin/admin-ajax.php)”. It reports only what the test saw happen to the form’s request. If the form also showed an error on the page, the message quotes it after “The form showed:”. If the site answered with success and the form showed no message, the error reads as before. For flows that log in with saved credentials, the form’s own message is not quoted.
- 403 Forbidden: usually a firewall, security plugin or host-level rule blocking CheckView. See Whitelisting CheckView IPs and Bypassing Security Plugin Blocks. A cached page with an expired nonce can also return a 403. See Fixing WordPress Nonce and Caching Issues.
- 401 Unauthorized: the address the form posts to is password protected, often HTTP authentication on
/wp-admin/. Allowadmin-ajax.phpthrough, or whitelist CheckView as above. - 404 Not Found: the address the form posts to is missing or hidden, for example by a security plugin that renames or blocks
/wp-admin/or the REST API. - 406 Not Acceptable: usually a security plugin or host firewall rejecting the request. See the whitelisting article above.
- 429 Too Many Requests: your host or a security plugin is limiting how often CheckView can send requests. See the whitelisting article above.
- 5xx (500, 502, 503, 52x and similar): the server hit an error or timed out while handling the form. Check your server and PHP error logs at the time of the test.
- 422 or another 4xx: the form plugin or site rejected the data it was sent. Check the test video for a message on the page and compare the test’s values with the form’s rules.
- The request failed or had no answer yet (“The form’s request to the site failed with …” or “The site had not answered the form’s request when the test checked”): the connection dropped, or the site was still working on the form when the test checked. A firewall or the host closing the connection, or a very slow form handler, can cause this.
Troubleshooting Steps:
- Verify Form Submission
- Form Configuration: Ensure that the form is correctly configured and that all required fields are filled out in the test script. Check for any mandatory fields that might be missing or incorrectly filled.
- Form Validation: Confirm that client-side and server-side validation rules are met. Ensure that there are no validation errors preventing the form from being submitted.
- Verify the CheckView WordPress Plugin is Active
- Installed and Active: Ensure that the CheckView WordPress plugin is installed and active, and verify it is not being blocked. If the plugin is inactive, your tests will still execute but are likely to fail, as the plugin is essential for validating successful test submissions. Additionally, an inactive plugin will not suppress recipient emails or send emails to CheckView’s test inbox for verification, potentially leading to incomplete or inaccurate test results.
- Prevent Query String (?) Redirects
- CheckView utilizes specialized query strings when conducting tests, such as:
https://domain.com/contact/?checkview_test_id=e1a71c03-ca90-44c1-afab-84e3924326e2To ensure tests can run properly, confirm that no plugins or site settings are redirecting URLs containing query strings. You can verify this by appending a parameter, such as ?test, to any URL on your site. If configured correctly, this should either load the same page with the appended query string or return a 404 error, not redirect to another page or remove the query string. Improper handling of query strings can interfere with CheckView’s ability to test forms and other site functionalities effectively.
- CheckView utilizes specialized query strings when conducting tests, such as:
- Check Database Connection
- Database Status: Verify that the database server is running and accessible. Check for any connection issues that might prevent data from being saved.
- Database Logs: Review the database logs for any errors or issues during the submission process. Look for any failed queries or other indications of problems.
- Review WordPress Settings
- Form Plugins: Ensure that the form plugin or custom form handler is correctly configured and updated. Check for any settings that might affect form submission and data storage.
- Submission Handling: Verify that the form submission handling logic is working as expected. Check for any errors in the code that might prevent data from being saved to the database.
- Inspect Server-Side Issues
- Server Logs: Check the server logs for any errors that might occur during form submission. Look for PHP errors, server misconfigurations, or other issues that might affect data saving.
- Form Processing Scripts: Ensure that any scripts responsible for processing the form submission are running correctly and without errors.
- Check for Additional Form Validation
- Custom Validations: Review any custom validation rules that might prevent the form from being submitted. Ensure that these rules are correctly implemented and not overly restrictive.
- Third-Party Interference: Check if any third-party plugins or scripts are interfering with the form submission process. Disable them temporarily to see if the issue is resolved.
- Test Environment Consistency
- Environment Match: Ensure that the test environment mirrors the production environment as closely as possible. Differences in configurations or data can affect the form submission process.
- Data Consistency: Make sure that the data used in the test environment is consistent and reflective of real-world usage. Inconsistent data can lead to unexpected behavior in form submissions.
Additional Tips:
- Wait for Submission Confirmation: Adjust the test script in Checkview.io to wait for a confirmation message or redirection after form submission.
- Robust Selectors: Use robust selectors that accurately target form fields and submission buttons. Avoid overly generic selectors that might fail to interact with the correct elements.
- Debugging with Developer Tools: Use the browser’s developer tools to inspect the form and understand why the submission is not being saved. This can help identify issues with validation or server-side processing.
- Professional Help: If issues persist, consider consulting with a web development expert or a testing specialist for a thorough analysis and tailored solutions.
Related Articles
- “The form did not send anything to the site” Error – The form never left the page
- Mastering Selectors in CheckView
- Whitelisting CheckView IPs and Bypassing Security Plugin Blocks
- Fixing WordPress Nonce and Caching Issues
- How to Whitelist CheckView’s IPs on Rocket.net Hosting — if your site is hosted on Rocket.net