What I want to do is iterate through a set of row results (field of interest 'x') and do something with it, all in mysql.
So, fetching the rows and looping. Something like (disregard the syntax please):
BEGIN (procedure)
SET
@need = SELECT (...)
LOOP @inside_row in @need
ANOTHER QUERY WHERE SOMETHING = @inside_row.x
END LOOP (when @need is all iterated)
END
Does anyone know if this is doable and how? Thank you very much...