MySQL Forums
Forum List  »  Views

SELECT from view crashes
Posted by: Daniele Donati
Date: May 18, 2015 04:18PM

Hi everyone,
today I ran a SELECT which leads MySQL cpu up to 75% on both Windows and Linux installation, causing the database to become totally locked and without the possibility to STOP the running process even after closing the calling thread ... I have to force the MySQL shutdown!!

Basically, what I have done is a SELECT which made use of both VIEWS and TABLES.
Something similar to the following:
SELECT V1.FIELD_1, T1.FIELD_2, T3.FIELD_3, T4.FIELD_4
FROM database1.VIEW1 AS V1
INNER JOIN database2.TABLE_2 AS T2 ON T2.ID = V1.ID_2
INNER JOIN database2.TABLE_3 AS T3 ON T3.ID = V1.ID_3
INNER JOIN database2.TABLE_4 AS T4 ON T4.ID = V1.ID_4
...

Before going on in deep, I'd like to know if "theorically" the mix of VIEWS/TABLES on a SELECT statement is admitted; if not, I'd like to know what are the limits.

Many thanks in advance.
Regards

Options: ReplyQuote


Subject
Views
Written By
Posted
SELECT from view crashes
4174
May 18, 2015 04:18PM
1387
May 18, 2015 09:42PM
1301
May 19, 2015 02:21AM
1303
May 19, 2015 11:27AM
1191
May 19, 2015 02:33AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.