title: laravel - SQLSTATE[HY000]: General error: 1364 Field 'password' doesn't have a default value
body: <p>*Asking for your help again please. Im getting the above error on registration module. This is working before. I tried to make a my profile edit page and then this happens. Hoping for your help please.. Thank you in advance * </p>
  
  <p><strong>User Controller:</strong></p>
  
  <pre><code>namespace App\Http\Controllers\User;
  
  use App\Http\Controllers\Controller;
  use Illuminate\Http\Request;
  use App\Model\user\user;
  use Illuminate\Support\Facades\Auth;
  use Illuminate\Validation\Rule;
  
  class UserController extends Controller
  {
  
      public function __construct()
      {
          $this-&gt;middleware('auth');
      }
      /**
       * Display a listing of the resource.
       *
       * @return \Illuminate\Http\Response
       */
      public function index()
      {
          $user = Auth::user();
          return view('user.user.show',compact('user'));
      }
  
      /**
       * Show the form for creating a new resource.
       *
       * @return \Illuminate\Http\Response
       */
      public function create()
      {
          //
      }
  
      /**
       * Store a newly created resource in storage.
       *
       * @param  \Illuminate\Http\Request  $request
       * @return \Illuminate\Http\Response
       */
      public function store(Request $request)
      {
          $this-&gt;validate(request(), [
              'name' =&gt; 'required',
              'email' =&gt; 'required|email',
              'password' =&gt; 'required|confirmed'
              ]);
  
          $user = User::create([
              'name' =&gt; request('name'),
              'email' =&gt; request('email'),
              ]);
          $user-&gt;password = bcrypt(request('password'));
          auth()-&gt;login($user);
  
          return redirect(route('index'));;
      }
  
  
      /**
       * Display the specified resource.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function show($id)
      {
          //
      }
  
      /**
       * Show the form for editing the specified resource.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function edit($id)
      {
          $user = Auth::user();
          return view('user.user.edit', compact('user'));
      }
  
      /**
       * Update the specified resource in storage.
       *
       * @param  \Illuminate\Http\Request  $request
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function update(Request $request, $id)
      {
          $this-&gt;validate(request(), [
              'email' =&gt; ['required','email',Rule::unique('users')-&gt;ignore($id)],
              'password' =&gt; ['required','password',Rule::unique('users')-&gt;ignore($id)]
               ]);
  
          //$user = Auth::user();       
          $user = Auth::user();
  
          $user-&gt;name = $request-&gt;name;
          $user-&gt;email = $request-&gt;email;
          $user-&gt;password = bcrypt($request-&gt;password);
          $user-&gt;firstname = $request-&gt;firstname;
          $user-&gt;middlename = $request-&gt;middlename;
          $user-&gt;lastname = $request-&gt;lastname;
          $user-&gt;nationality = $request-&gt;nationality;
          $user-&gt;gender = $request-&gt;gender;
          $user-&gt;civilstatus = $request-&gt;name;
          $user-&gt;mobilenum = $request-&gt;mobilenum;
          $user-&gt;worknum = $request-&gt;worknun;
          $user-&gt;workadd = $request-&gt;workadd;
          $user-&gt;homeadd = $request-&gt;homeadd;
          $user-&gt;email = $request-&gt;email;
          $user-&gt;birthday = $request-&gt;birthday;
  
          $user-&gt;save();
  
          return redirect(route('user.user.show'))-&gt;with('message','Announcement Updated Succesfully');;
  
      }
  
      /**
       * Remove the specified resource from storage.
       *
       * @param  int  $id
       * @return \Illuminate\Http\Response
       */
      public function destroy($id)
      {
          //
      }
  
  </code></pre>
  
  <p><strong>Blade file:</strong></p>
  
  <pre><code>                    &lt;form method="POST" action="{{ route('register') }}"&gt;
                          @csrf
                      &lt;div class="text-center"&gt;&lt;button class="btn btn-primary text-left" style="width: 100%;" type="button"&gt;&lt;i class="fa fa-facebook"&gt;&lt;/i&gt;&amp;nbsp; Continue with Facebook&lt;/button&gt;&lt;/div&gt;
                      &lt;div class="text-center mt-2"&gt;&lt;button class="btn btn-light text-left border-dark" style="width: 100%;" type="button"&gt;&lt;i class="fa fa-google"&gt;&lt;/i&gt;&amp;nbsp; Continue with Google&lt;/button&gt;&lt;/div&gt;
                      &lt;form class="mt-4"&gt;
                          &lt;div class="form-group"&gt;
                              &lt;div class="input-group"&gt;
                                  &lt;div class="input-group-prepend"&gt;&lt;span class="text-primary input-group-text"&gt;&lt;i class="fa fa-user-o"&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;input class="form-control @error('name') is-invalid @enderror" name="name" value="{{ old('name') }}" required autocomplete="name" autofocus placeholder="Full Name"&gt;
                                  @error('name')
                                  &lt;span class="invalid-feedback" role="alert"&gt;
                                      &lt;strong&gt;{{ $message }}&lt;/strong&gt;
                                  &lt;/span&gt;
                              @enderror
                                  &lt;div class="input-group-append"&gt;&lt;/div&gt;
                              &lt;/div&gt;
                          &lt;/div&gt;
                          &lt;div class="form-group"&gt;
                              &lt;div class="input-group"&gt;
                                  &lt;div class="input-group-prepend"&gt;&lt;span class="text-primary input-group-text"&gt;&lt;i class="fa fa-envelope-o"&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;input class="form-control @error('email') is-invalid @enderror" name="email" value="{{ old('email') }}" required autocomplete="email" placeholder="Email"&gt;
                                  @error('email')
                                  &lt;span class="invalid-feedback" role="alert"&gt;
                                      &lt;strong&gt;{{ $message }}&lt;/strong&gt;
                                  &lt;/span&gt;
                              @enderror
                                  &lt;div class="input-group-append"&gt;&lt;/div&gt;
                              &lt;/div&gt;
                          &lt;/div&gt;
                          &lt;div class="form-group"&gt;
                              &lt;div class="input-group"&gt;
                                  &lt;div class="input-group-prepend"&gt;&lt;span class="text-primary input-group-text"&gt;&lt;i class="fa fa-lock"&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;input class="form-control @error('password') is-invalid @enderror" name="password" required autocomplete="new-password" placeholder="Password" type="password"&gt;
                                  @error('password')
                                  &lt;span class="invalid-feedback" role="alert"&gt;
                                      &lt;strong&gt;{{ $message }}&lt;/strong&gt;
                                  &lt;/span&gt;
                              @enderror
                                  &lt;div class="input-group-append"&gt;&lt;/div&gt;
                              &lt;/div&gt;
                          &lt;/div&gt;
                          &lt;div class="form-group"&gt;
                              &lt;div class="input-group"&gt;
                                  &lt;div class="input-group-prepend"&gt;&lt;span class="text-primary input-group-text"&gt;&lt;i class="fa fa-lock"&gt;&lt;/i&gt;&lt;/span&gt;&lt;/div&gt;&lt;input class="form-control" name="password_confirmation" required autocomplete="new-password" placeholder="Confirm Password" type="password"&gt;
                                  &lt;div class="input-group-append"&gt;&lt;/div&gt;
                              &lt;/div&gt;
                          &lt;/div&gt;
  </code></pre>
  
  <p><strong>Model/users/user.php</strong></p>
  
  <pre><code>use Illuminate\Notifications\Notifiable;
  use Illuminate\Contracts\Auth\MustVerifyEmail;
  use Illuminate\Foundation\Auth\User as Authenticatable;
  
  class User extends Authenticatable
  {
      use Notifiable;
  
      /**
       * The attributes that are mass assignable.
       *
       * @var array
       */
      protected $fillable = [
          'name', 'email', 'firstname', 'middlename', 'lastname', 'birthday', 'nationality', 
          'gender', 'civilstatus', 'mobilenum', 'worknum', 'workadd',
          'homeadd', 
      ];
  
      /**
       * The attributes that should be hidden for arrays.
       *
       * @var array
       */
      protected $hidden = [
          'password', 'remember_token',
      ];
  }
  </code></pre>
  
  <p>Please help me. Thank you in advance</p>