We just moved a site from development to live and now get the following error when trying to download a product:
Unable to insert download log entry in database.
The WordPress error log shows the following entry:
16-Nov-2018 05:20:54 UTC] WordPress database error Cannot add or update a child row: a foreign key constraint fails (`livesite_wp522`.`wplive_wc_download_log`, CONSTRAINT `fk_wc_download_log_permission_id` FOREIGN KEY (`permission_id`) REFERENCES `wpdev_woocommerce_downloadable_product_permissions` (`permission_id) for query INSERT INTO `wp01_wc_download_log` (`timestamp`, `permission_id`, `user_id`, `user_ip_address`) VALUES ('2018-11-16 05:20:54', '37', NULL, '[login to view URL]') made by require('[login to view URL]'), require_once('[login to view URL]'), require_once('[login to view URL]'), require_once('[login to view URL]'), do_action('init'), WP_Hook->do_action, WP_Hook->apply_filters, WC_Download_Handler::download_product, WC_Customer_Download->track_download, WC_Data->save, WC_Data_Store->create, WC_Customer_Download_Log_Data_Store->create, QM_DB->query
To see the issue you can go here: [login to view URL] and checkout one of the "By Donation" downloads with a payment of $0.
We need to fix this to get the downloads to work again.
9 freelancers estão ofertando em média $27 para esse trabalho
Hello, I can fix your issue on download on your wordpress site as per your given brief on project post. Let me know when you available to discuss more in detailed. Regards Rina
Hello How are you My name is Xu I can fix it in 5 min i have full time and I can start to work immediately Please contact me and do let us discuss about your project Thanks for your posting