![]() |
Cannot create a new category When I try to create a new category I get this error Error adding new category to the "database." Returned id was "0." Thanks |
Please in admin => global options set your debug setting to display errors and then try again and post the real mysql error so we may assist. |
Quote:
After doing the above the error reads We're sorry, but the system experienced an unrecoverable error. Please try again later. Script: adm-cats Query: INSERT INTO pp_categories (id,catname,description,catorder,thumbs,parent,header,footer,headtags,password,ugnoview,ugnoupload,ugnopost,ugnoanno,ugnovote,watermark,sortorder,frames,maximages,ratingtype,ismember) VALUES(NULL,'Newbury','','3','yes',584,'','','','', '', '1,3,4,8,9,10,11,13', '1,2,3,4,5,7,8,9,10,11,13,14', '1,2,3,4,5,6,7,8,9,10,11,13,14', '2', '2', '0', '0', '', '', '') Result: Incorrect integer value: '' for column 'maximages' at row 1 Database handle: Resource id #20 |
In Layman's terms MySQL in strict mode can not allow query inserts with null values to be entered. Workaround There are several workarounds 1. Replace in my.ini the current sql-mode line with sql-mode="MYSQL40" 2. Start MySQL with the option --sql-mode="MYSQL40" 3. Execute the query SET GLOBAL sql_mode='MYSQL40' MySQL needs to be restarted before changes in my.ini have an effect. My.ini can be found in the MySQL installation directory or the Windows directory, depending on your configuration. |
Thanks Chuck, I have found the line Quote:
Thanks |
There should none most servers run in compatiblity mode and not strict mode. You can also try just removing this and remember to restart the server STRICT_TRANS_TABLES |
| All times are GMT -5. The time now is 08:54 PM. |
Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0