Field 'position' doesn't have a default value

Results 1 to 5 of 5
  1. #1
    Member Angel1303 is offline
    MemberRank
    Feb 2011 Join Date
    UKLocation
    59Posts

    Field 'position' doesn't have a default value

    does anyone have a fix for this
    Field 'position' doesn't have a default value
    would help thanks


  2. #2
    Lurking around Clawed is offline
    MemberRank
    Jun 2012 Join Date
    RaGEZONELocation
    785Posts

    Re: Field 'position' doesn't have a default value

    Code:
    ALTER TABLE %table% MODIFY %column% %type% DEFAULT '%value%';
    %table% = table of course.
    %column% = the column name.
    %type% = this is a few examples, int(11) or varchar(255)
    %value% = the value of the default column.

  3. #3
    Member Angel1303 is offline
    MemberRank
    Feb 2011 Join Date
    UKLocation
    59Posts

    Re: Field 'position' doesn't have a default value

    Quote Originally Posted by Clawed View Post
    Code:
    ALTER TABLE %table% MODIFY %column% %type% DEFAULT '%value%';
    %table% = table of course.
    %column% = the column name.
    %type% = this is a few examples, int(11) or varchar(255)
    %value% = the value of the default column.
    so i copy that code and run the query then

  4. #4
    Lurking around Clawed is offline
    MemberRank
    Jun 2012 Join Date
    RaGEZONELocation
    785Posts

    Re: Field 'position' doesn't have a default value

    Quote Originally Posted by Angel1303 View Post
    so i copy that code and run the query then
    Yea so it should be something like:
    Code:
    ALTER TABLE users MODIFY position int(11) DEFAULT '0';
    That's just an example, now just edit it to you table and column specifications.

  5. #5
    Member Angel1303 is offline
    MemberRank
    Feb 2011 Join Date
    UKLocation
    59Posts

    Re: Field 'position' doesn't have a default value

    Quote Originally Posted by FatalLulz View Post
    Go to your database, open it, now if you're using Navicat right click the user column, click design table, scroll down to you see where it says 'position' and make sure it's default is set to NULL like this;



    OR if you use Xampp go to your link/phpmyadmin, select your database, go to the users table, click the structure button, scroll down till you see position, click edit (the pencil icon to the right of it) and set it's default to NULL.
    ty fataLulz i dont use xmapp you should know that i useing iis but i folow your step as it works well thanks anyway u 2



Advertisement