-1
My select is returning the field and value of the id that is in the table and need to return only the value,?
$id = DB::table('participantes')
->select('id')
->orderBy('id','DESC')
->take(1)
->get();
Error returned
SQLSTATE[22007]: Invalid datetime format: 1366 Incorrect integer value: '[{"id":173}]' for column 'participante_id' at Row 1 (SQL: Insert into
participantes
(opcao_id
,questao_id
,participante_id
) values (291, 84, [{"id":173}]))
Do you know that
get
is different fromfirst
right?– Wallace Maxters