TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 629
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 413
  • Total: 413

"subtype" has no default value error message (SMF 1.1.3, TP 0983)

Started by Wivelrod, July 24, 2007, 04:50:36 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

splattercaster

OK I fixed the adding an article to no category error, by following these instructions:

http://www.tinyportal.net/index.php?topic=13328.0

I now just have this error when adding a new category:
Database Error: Field 'subtype' doesn't have a default value
File: C:\Webroot_UKDK\Sources\TPortalAdmin.php
Line: 404

I tried to fix it following the example above by adding
if(empty($catp))
  $catp = 0;

before line 404:
db_query("INSERT INTO {$tp_prefix}variables (value1,value2,value3,type,value4,value5) VALUES('$catn','$catp','','category','',0)", __FILE__, __LINE__);

but it didn't help and causes a hang instead of the error.

Any ideas or links on this forum to fix this, I searched but couldn't find any.

Cheers

G6Cad

I have been searching a lot on this now.
For most a DB upgrade fixes the issue with that error, but then i found this topic.
Can you please read and try and give the info asked of that member there.
http://www.tinyportal.net/index.php?topic=15331.10

splattercaster

Yeh, I'd already read that thread mate. The one where bloc quotes
QuoteYes, its def. MySQL5 or PHP5 trouble. I will work out a fix for you on that pending newer versions of TP.

And unfortunately I can't upgrade php or SQL on the server as tcwright suggests as it hosts multiple websites & forums and would probably cause problems.

I guess information about the correct table attributes would be useful then I can modify them to correct the issue.

Thanks for looking though.  :up:

Kronos

Hello, I've just successfully manualy installed tinyportal on my SMF board.
Now I've got the same problems as the previous posters in this topic so I thought I'd bump it.

When I try to add an article category it gives the following error:
Field 'subtype' doesn't have a default value
File: ...\SMF\Sources\TPortalAdmin.php
Line: 404


And when I attempt to add an article to one of the allready existing demo categories:
Field 'shortname' doesn't have a default value
File: ...\SMF\Sources\TPortalAdmin.php
Line: 463


I haven't encountered any other errors so far but if I do I'll post them.

Thanks in advance.

Also I'd like to tell you that I'm not particulary good with php, this might make it a bit harder.

G6Cad

You installed what inside what ?
Start a new topic and refer to this topic, but we still need to know your setup according to the posting guidelines.  ;)

This website is proudly hosted on Crocweb Cloud Website Hosting.