Of course I was not hoping that SPs would be actually compiled but it seems to me they are not even interpreted. I have a preprocessing table of 170k rows in a ~72 MB table. A stored procedure with a lot of string operations processes the data into another table of approx 15 million rows( few hundred megs). However as the SP is being executed, the mysqld process rapidly uses up all the memory(2G) and then just gets stuck. No records are inserted at all! Not even the tracer lines I insert before I open my cursor! If I reduce the recordset the SP passes smoothly without using up all the memory.So the problem is not with my code! It seems like MySQL first reads the whole cursor into memory and generates millions of lines of SQL code, then executes these lines at once. If that is the case I think it is really bad design! I dont want to raise a bug about this bottleneck, because probably it is covered by the many SP related bugs, but I am really curious how SPs are actually processed? -- Bereczki Gabor <[EMAIL PROTECTED]>
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]