AnsweredAssumed Answered

SQL run long time

Question asked by sysoncloud on Aug 30, 2017
Latest reply on Sep 5, 2017 by janv


I have a server running Alfresco 3.4.d community, DBA monitor one SQL run very slow,  the max time it cost 3.8 minutes, how to analysis the possible bottleneck or any idea?  thank you in advance.


select as id, as parentNodeId,
parentStore.protocol as parentNodeProtocol,
parentStore.identifier as parentNodeIdentifier,
parentNode.uuid as parentNodeUuid, as childNodeId,
childStore.protocol as childNodeProtocol,
childStore.identifier as childNodeIdentifier,
childNode.uuid as childNodeUuid,
assoc.type_qname_id as type_qname_id,
assoc.child_node_name_crc as child_node_name_crc,
assoc.child_node_name as child_node_name,
assoc.qname_ns_id as qname_ns_id,
assoc.qname_localname as qname_localname,
assoc.is_primary as is_primary,
assoc.assoc_index as assoc_index
alf_child_assoc assoc
join alf_node parentNode on ( = assoc.parent_node_id)
join alf_store parentStore on ( = parentNode.store_id)
join alf_node childNode on ( = assoc.child_node_id)
join alf_store childStore on ( = childNode.store_id)
where = $1 and
childNode.type_qname_id in ($2,$3,$4,$5,$6,$7,$8,$9,$10)
order by assoc.assoc_index ASC, ASC