SQL error upgrading from 2.7.6 to 2.8.1 (assignedby)

Helpdesk for my helpdesk software

Moderator: mkoch227

Post Reply
xbach
Posts: 23
Joined: Tue Aug 17, 2010 12:07 pm

SQL error upgrading from 2.7.6 to 2.8.1 (assignedby)

Post by xbach »

Script URL:
Version of script: 2.8.1
Hosting company: Consell Comarcal del Baix Empordà
URL of phpinfo.php:
URL of session_test.php:
What terms did you try when SEARCHING for a solution:
I looked at knowledge and forum

Write your message below:

After upgrading to 2.8.1 I received an error saying:
Can't execute SQL: ALTER TABLE 'hesk_tickets' ADD 'assignedby' MEDIUMINT NULL DEFAULT NULL AFTER 'owner', ADD INDEX ('assignedby')

MysSQL said:
Invalid default value for 'dt'


What is wrong? I've tested it and now I can't assign tickets to others.

Thanks a lot!
xbach
Posts: 23
Joined: Tue Aug 17, 2010 12:07 pm

Re: SQL error upgrading from 2.7.6 to 2.8.1 (assignedby)

Post by xbach »

Hi again!
I've resolved the issue by myself. The way I've done is by disabling MySQL strict mode. Is the only way I found.

I've done it the way Bilal tells in this post: https://askubuntu.com/questions/811831/ ... was-in-5-6

If there is another way to do it without disabling strict mode, please let me now.

Thanks,
Klemen
Site Admin
Posts: 10143
Joined: Fri Feb 11, 2005 4:04 pm

Re: SQL error upgrading from 2.7.6 to 2.8.1 (assignedby)

Post by Klemen »

This means one of the older updates didn't go through, the dt columns should be updated already in 2.7.6

You can run this query to update the dt column:

Code: Select all

ALTER TABLE `hesk_tickets` CHANGE `dt` `dt` timestamp NOT NULL DEFAULT '2000-01-01 00:00:00'
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Post Reply