Upcoming Events
2024-11-04 @ 09:00 - 17:00
Whether you’re aiming to be the next great query tuning wizard or you simply need to tackle tough business problems at work...read more
2024-11-05 @ 09:00 - 17:00
Picture this: a day crammed with fun, fascinating demonstrations for SQL Server and Azure SQL. This isn’t your typical training day; this session follows the mantra of “learning by doing,” with...read more
2024-09-06 @ 09:00 - 17:00
Whether you want to be the next great query tuning wizard, or you just need to learn how to start solving tough business problems at work, you need a solid understanding of not only what makes things fast, but also what makes them slow.
Hey Erik,
We’re using one of the views (HumanEvents_Queries) to check on the SP calling parameters, along with the rest of that useful info. We noticed that, in case of a .Net SqlClient Data Provider (as client app), no parameters are shown in the ‘sql_text’ view column. The column value looks like this:
(@p0 int,@p1 bit)exec dbo.MVT_ClickThroughrateGet @p0, @p1
Would it be reasonable to assume that the active extended event (keeper_HumanEvents_queries) failed to capture the params or would it be possible to find them stored in some other extended event field ?
Thanks !
Interesting! I haven’t run into that. Are they in the query plan?
Yes, they are in the query plan. Here’s a screen capture:
https://ibb.co/KX77cbV
I see, yeah, not sure I can do anything about that.
That’s pretty odd, I had a better look and I guess it’s about the way query plan is formed/saved (by the extended event session ?).
I ran the statement directly in SSMS. Here’s the query plan:
https://ibb.co/KK41PZH
As you expect, when running a SELECT statement, the left most operator (NodeId = 0) is ‘SELECT’. Also, the statement is visible (under ‘Query 1’ tag).
BUT, if I click on the ‘showplan_xml’ view column, here’s what i see:
https://ibb.co/Y4S0bWm
Now, the left most operator is ‘Compute Scalar’ and the statement is not visible.
So it seems that the ‘showplan_xml’ column contains an incomplete XML.
Still, I was able to find the parameter value, by opening the column value as a string:
https://ibb.co/Dghx4QC
Forgot to mention the SQL Server version:
Microsoft SQL Server 2014 (SP3-GDR) (KB4505218) – 12.0.6108.1 (X64)
May 29 2019 20:05:27
Enterprise Edition: Core-based Licensing (64-bit) on Windows NT 6.3 (Build 9600: )
Yep, that happens in Extended Events sometimes.