The reason your data looks like it does is inserts create new records. Your code would work if the 2nd loop did updates instead of inserts.
Ikegami's suggestion is the right way to do it. I just thought you'd like to know why your code did what it's doing.
In reply to Re: Inserting 2 arrays into 2 field in MySQL
by pileofrogs
in thread Inserting 2 arrays into 2 field in MySQL
by poolboi
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |