Answer the question
In order to leave comments, you need to log in
Why save() doesn't save certain options?
Hey!
Restriction or not - I do not understand. I didn’t find an answer in the documentation ... I
save it like this, despite the fact that the fields in the table are (id, param1, param2)
$app= new App;
$app->param1= 1;
$app->param2= 2;
$app->save();
$app= new App;
$app->param1= 1;
$app->param2= 2;
$app->param3= '';
$app->save();
Answer the question
In order to leave comments, you need to log in
As far as I understand the question, you need to set the default value for param3 to Null
Everything is fine with me when the parameters are only partially set
Turn on the debug in .env - it will tell you what exactly is wrong
And it looks like Guerrka is right - set the default value in the database itself - null
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question