Page 1 of 1

Data truncated for column 'overdue_email_sent' at row 1

Posted: Wed Apr 28, 2021 4:01 pm
by OCReactive
Script URL:
Version of script: 3.2.2
Hosting company: own server
URL of phpinfo.php: https://justpaste.it/8d72m
URL of session_test.php: OK: PHP sessions work fine
What terms did you try when SEARCHING for a solution: Data truncated for column, Can't execute SQL

Write your message below:

I'm having this error when trying to modify the due date, if I set a due date when creating the ticket it works well.

Code: Select all

Error

Can't execute SQL: UPDATE `hesk_tickets` SET `due_date` = '2021-04-29', `overdue_email_sent`=0, `history`=CONCAT(`history`,'

2021-04-28 17:47:13 | due date updated to 2021-04-29 by John Smith(jsmith)
') WHERE `trackid`='HS2-REZ-48EQ' AND (`due_date` IS NULL OR `due_date` != '2021-04-29')

MySQL said:
Data truncated for column 'overdue_email_sent' at row 1
 

WARNING
Debug mode is enabled. Make sure you disable debug mode in settings once HESK is installed and working properly.

Re: Data truncated for column 'overdue_email_sent' at row 1

Posted: Wed Apr 28, 2021 6:29 pm
by Klemen
What is the structure of your hesk_tickets table? Can you check in phpMyAdmin and post it here (export just structure, no data)?

Re: Data truncated for column 'overdue_email_sent' at row 1

Posted: Thu Apr 29, 2021 2:35 pm
by OCReactive
Hope I've done rigth, I'm not an expert in DDBB https://justpaste.it/8rfsa

Re: Data truncated for column 'overdue_email_sent' at row 1

Posted: Thu Apr 29, 2021 4:57 pm
by Klemen
Looks like your database was from Mods for Hesk and as such not properly updated to Hesk 3 style.

Try this:
1. go to phpMyAdmin
2. BACKUP existing hesk_tickets table
3. on the "Structure" tab, change overdue_email_sent type from ENUM to TINYINT. Set default value to 0 (no quotes)
4. save and test

Re: Data truncated for column 'overdue_email_sent' at row 1

Posted: Thu Apr 29, 2021 6:07 pm
by OCReactive
It worked like a charm, thank you so much ;)