1
I’m making the following mistake
Error: Data Too long for column 'options' at Row 1
This is my code:
$arr = Array();
foreach($_POST['opcoes'] AS $n=> $m) {
$p = explode("|", $m);
$arr[] = $p[1]."-".$_POST['opcoes'][$n];
$i++;
}
$opcoes = implode(",", $arr);
$rs = $mysqli->prepare("INSERT INTO tabela (nome1,nome2,opcoes) VALUES (?,?,?)");
$rs->bind_param('sss', $_POST['nome1'], $_POST['nome2'], $opcoes);
How to correct this error?
You are in error: Big data for column! Increase column or decrease number of characters.
– rbz