Open kmligue opened 9 years ago
you should also paste some dataform/dataedit code about the insertion and some relevant part of model (if you used a model)
That query is very wrong, not sure if it eloquent or the logger to be wrong.
A workaround would be to set the fields as ->nullable().
This is my DataForm:
$create = \DataForm::source(new Contacts);
$create->link("contacts","Contacts", "TR")->back();
$create->add('first_name','First Name', 'text')->rule('required');
$create->add('last_name','Last Name','text');
$create->submit('save');
return $create->view('contacts.create', compact('create'));
I've tried DataEdit also but the error is still the same.
last name should be nullable as @tacone said or you must add a required rule for last_name too.
I have this migration
First name is required. Everytime i do insertion in that table it will display an error
Should the query have '' on empty field?