I have a pool of 100 users who have answered a question. Only about 10% of those users will choose the right answer.
I want to create a new table, with a row for every one of the 90% who answered wrong, with their username and the wrong answer they provided.
What is the best way to do that?
Should I first create an array of the usernames who entered the wrong answer, then, do a foreach loop, with an INSERT MySQL for each iteration?
Or is there a MySQL way to get the approach "apply to all who have NOT answer right"?
Thanks a lot. Regards
foreachyou would then execute the statement. Alternatively,INSERTsupports multiple rows in a single SQL query.