Cursor's base query

1

Hello, I see "fetch xx from curxx" queries taking long to run - how do I identify the declared cursor query?

Using the pid when I am looking to svl_qlog or stl_query, I see the session has -

2019-06-18 16:08:53	2019-06-18 16:08:53 SELECT COUNT(*) FROM sometable LIMIT 1 OFFSET 0  
2019-06-18 16:08:58	2019-06-18 16:51:39	FETCH 200 FROM CUR0```  
  
The fetch query seems to be running for long, fetching lots of data but the count(*) could not be the query from where its pulling the data. So how do I identify the base query. Would the pid change for the fetch query, if so how to co-relate them?  
  
Edited by: nmakb on Jun 18, 2019 2:19 PM
  • By any chance, did you find a solution for it?

nmakb
已提問 5 年前檢視次數 170 次
1 個回答

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南