How can I get the rows from SHOW PROCESSLIST using MySQL Connector for .NET or Dapper?

I need to parse the running queries on my MySQL server. What is the easiest way to retrieve the result of SHOW PROCESSLIST from within MySQL Connector for .NET, or using Dapper?

Maybe something like (with Dapper):

var rows = connection.Query("SHOW PROCESSLIST");

Answers


The results of most MySQL meta-commands are represented in the INFORMATION_SCHEMA pseudo-database:

SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST

Need Your Help

How can I get a script's output to be copied to the Windows clipboard?

windows perl scripting batch-file clipboard

I find myself running scripts and copy-pasting the output of these runs into emails or into some other documents. Is there a way such that I can make the copy-to-clipboard step a part of the script

appendTo does not work on ajaxForm in success:

jquery

I want to append quest1 to #adder, but just does not happen

Where should I store constant data and then how to reference it in Rails?

ruby-on-rails ruby-on-rails-3 mongoid

I have a array of data, for example times (7:00am, 7:30am, etc.), that I want stored and referenced in a couple places.