DB error - creating tables
Moderator: mkoch227
DB error - creating tables
Script URL: http://66.45.88.170/hesk/index.php?a=start
Version of script: 0.93.1
Version of PHP: 4.4.1
Hosting company: myself
Have you searched THIS FORUM for your problem: yes
If so, what terms did you try: db error, creating mysql, Couldn't execute SQL: CREATE TABLE
Write your message below:
Got DB to connect.
Cannot get tables to build. Error below.
Couldn't execute SQL: CREATE TABLE `hesk_categories` ( `id` smallint(5) unsigned NOT NULL auto_increment, `name` varchar(20) NOT NULL default '', PRIMARY KEY (`id`) ) TYPE=MyISAM. Please make sure you delete any old installations of Hesk before installing this version!
Does the user need certain permissions other than db_owner?
Nex
Version of script: 0.93.1
Version of PHP: 4.4.1
Hosting company: myself
Have you searched THIS FORUM for your problem: yes
If so, what terms did you try: db error, creating mysql, Couldn't execute SQL: CREATE TABLE
Write your message below:
Got DB to connect.
Cannot get tables to build. Error below.
Couldn't execute SQL: CREATE TABLE `hesk_categories` ( `id` smallint(5) unsigned NOT NULL auto_increment, `name` varchar(20) NOT NULL default '', PRIMARY KEY (`id`) ) TYPE=MyISAM. Please make sure you delete any old installations of Hesk before installing this version!
Does the user need certain permissions other than db_owner?
Nex
No other permissions are required. Perhaps you already have the tables installed? Have you tried if posting tickets in Hesk works normally?
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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
Submit ticket
I tried to submit a ticket and this is what i got.....
Error
Can't execute SQL: INSERT INTO `hesk_tickets` ( `id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status` ) VALUES ( '', '2UPN6GUYYY','Lance Brown','lance@bigrockford.com','1','3','test','test',NOW(),'67.176.30.202','1' )
MySQL said:
Incorrect integer value: '' for column 'id' at row 1
Please notify webmaster at lbrown@hostedcti.com
Lance
Error
Can't execute SQL: INSERT INTO `hesk_tickets` ( `id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status` ) VALUES ( '', '2UPN6GUYYY','Lance Brown','lance@bigrockford.com','1','3','test','test',NOW(),'67.176.30.202','1' )
MySQL said:
Incorrect integer value: '' for column 'id' at row 1
Please notify webmaster at lbrown@hostedcti.com
Lance
If you check thru phpMyAdmin are the tables created? If yes try using the "repair tables" link.
If that doesn't work delete the tables and try installing again.
Regards
If that doesn't work delete the tables and try installing again.
Regards
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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
-
- Posts: 4
- Joined: Sat Jan 21, 2006 4:23 am
same here
all seems good till i submit the new ticket i get this error
Can't execute SQL: INSERT INTO `hesk_tickets` ( `id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status` ) VALUES ( '','7U3DPGSPQM','----','*************@yahoo.com','1','3','help','yo',NOW(),'' )
MySQL said:
Incorrect integer value: '' for column 'id' at row 1
i deleted and reinstalled the databases but i still get the same error!
i also get this error when useing the category management and i try to add a new category!
I'm useing all the latest versions of hesk, apache, phpmyadmin and mysql on a windows 2003 server
Can't execute SQL: INSERT INTO `hesk_tickets` ( `id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status` ) VALUES ( '','7U3DPGSPQM','----','*************@yahoo.com','1','3','help','yo',NOW(),'' )
MySQL said:
Incorrect integer value: '' for column 'id' at row 1
i deleted and reinstalled the databases but i still get the same error!
i also get this error when useing the category management and i try to add a new category!
I'm useing all the latest versions of hesk, apache, phpmyadmin and mysql on a windows 2003 server
What's the version of PHP?
Check in phpMyAdmin if all id collums have auto_increment
What version of MySQL are you running (the extact version, not "latest")? If possible try with version 4.x and see if that helps?
Check in phpMyAdmin if all id collums have auto_increment
What version of MySQL are you running (the extact version, not "latest")? If possible try with version 4.x and see if that helps?
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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
Before you try with different MySQLversion, can you upload this file over the original one and see if you can successfully submit a ticket?
http://www.phpjunkyard.com/extras/submi ... mysql5.zip
http://www.phpjunkyard.com/extras/submi ... mysql5.zip
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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
-
- Posts: 4
- Joined: Sat Jan 21, 2006 4:23 am
-
- Posts: 4
- Joined: Sat Jan 21, 2006 4:23 am
Seems like MySQL 5 is very strict about some things, please try with these files instead of original ones:
http://www.phpjunkyard.com/extras/mysql5_fix.zip
Please test all the features (posting ticket, replying by admin, replying by customer, adding categories, adding users) and then post back if all works ok.
Regards
http://www.phpjunkyard.com/extras/mysql5_fix.zip
Please test all the features (posting ticket, replying by admin, replying by customer, adding categories, adding users) and then post back if all works ok.
Regards
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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
-
- Posts: 4
- Joined: Sat Jan 21, 2006 4:23 am
Re: Submit ticket
nexusdsl wrote:I tried to submit a ticket and this is what i got.....
Error
Can't execute SQL: INSERT INTO `hesk_tickets` ( `id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status` ) VALUES ( '', '2UPN6GUYYY','Lance Brown','lance@bigrockford.com','1','3','test','test',NOW(),'67.176.30.202','1' )
MySQL said:
Incorrect integer value: '' for column 'id' at row 1
Please notify webmaster at lbrown@hostedcti.com
Lance
should loose empty quotes that corerspond to id and put NULL instead OR loose id and '' at all - MySQL take care of auto increment fields on its own, you should apply this changes to submit_ticket.php
should look like that: $sql = "
INSERT INTO `hesk_tickets` (
`id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status`
)
VALUES (
NULL,'$trackingID','$name','$email','$category','$priority','$subject','$message',NOW(),'$_SERVER[REMOTE_ADDR]','1'
)
";
instead of
$sql = "
INSERT INTO `hesk_tickets` (
`id`,`trackid`,`name`,`email`,`category`,`priority`,`subject`,`message`,`dt`,`ip`,`status`
)
VALUES (
'','$trackingID','$name','$email','$category','$priority','$subject','$message',NOW(),'$_SERVER[REMOTE_ADDR]','1'
)
";
The file 2 posts above your post fixes the problem
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here 
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


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