"parameter {0} must be a real scalar" error when using parfor
Mostrar comentarios más antiguos
Hello,
In the following parfor loop, I want to add data into a newly created column in a mysql table by going row by row and manually inserting the data using the "update" function. But I end up getting an error, saying that the parameter isn't a scalar. I'm not sure why the error occurs since the beginning and ending values of the loop are both scalars. And if I replace "sizeOfColumn" with a literal constant, it also gives me the same error.


Thank You so much.
1 comentario
Walter Roberson
el 1 de Abr. de 2022
I wonder if you need to use
data = newColumn(i,1);
?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Loops and Conditional Statements en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!