View Issue Details

IDProjectCategoryView StatusLast Update
0028240mantisbtdb mysqlpublic2021-05-12 09:34
Reportersintaq Assigned Todregad  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionno change required 
Summary0028240: High cost statement based on MySQL Workbench performance report
Description

Got 2 statement that interest me. Are these normal?

Below is the statement that executed with highest number but 0 warning. Refer image 2
SELECT ( cat . name COLLATE utf8_tolower_ci ) AS TABLE_CATALOG , ( sch . name COLLATE utf8_tolower_ci ) AS TABLE_SCHEMA , ( tbl . name COLLATE utf8_tolower_ci ) AS TABLE_NAME , tbl . type AS TABLE_TYPE , IF ( ( tbl . type = ? ) , tbl . engine , ? ) AS ENGINE , IF ( ( tbl . type = ? ) , ?, ... ) AS VERSION , tbl . row_format AS ROW_FORMAT , IF ( ( tbl . type = ? ) , ? , internal_table_rows ( sch . name , tbl . name , IF ( ( tbl . partition_type IS NULL ) , tbl . engine , ? ) , tbl . se_private_id , ( tbl . hidden != ? ) , ts . se_private_data , COALESCE ( stat . table_rows , ? ) , COALESCE ( CAST ( stat . cached_time AS UNSIGNED ) , ? ) ) ) AS TABLE_ROWS , IF ( ( tbl . type = ? ) , ? , internal_avg_row_length ( sch . name , tbl . name , IF ( ( tbl . partition_type IS NULL ) , tbl . engine , ? ) , tbl . se_private_id , ( tbl . hidden != ? ) , ts . se_private_data , COALESCE ( stat .

Another statement is below with the highest warning. Refer image 1
SET NAMES 'UTF8'

TagsNo tags attached.
Attached Files
image.png (176,607 bytes)   
image.png (176,607 bytes)   
image-2.png (25,330 bytes)   
image-2.png (25,330 bytes)   

Activities

dregad

dregad

2021-04-12 10:06

developer   ~0065366

the statement that executed with highest number but 0 warning

You have not pasted the whole SQL, but it seems like it's querying the information_schema.
That does not look like a MantisBT query at all; I don't think the underlying ADOdb library perform such kind of queries either.
Maybe you have some other tool executing queries against the Mantis schema ?

Another statement is below with the highest warning. Refer image 1
SET NAMES 'UTF8'

The high usage is easily explained, as the statement is executed whenever the database API is initialized (i.e. connection is established), as documented here): Applications that use the database should also configure their connection to the server each time they connect. This can be done by executing a SET NAMES 'utf8' statement after connecting.

As for the warning, I don't know - maybe you can tell us more about what it is ?

atrol

atrol

2021-04-25 13:48

developer   ~0065432

sintaq,

You did not provide any feedback; I am therefore resolving this issue as "no change required".

Feel free to reopen the issue at a later time and provide the requested information.