[HACKERS] About adding new output parameter of pg_stat_statements to identifyoperation of the query. - Mailing list pgsql-hackers

From jasonysli(李跃森)
Subject [HACKERS] About adding new output parameter of pg_stat_statements to identifyoperation of the query.
Date
Msg-id 4D26F97E8B8D884898ABE03333C1CD79FA3A2B52@EXMBX-SZMAIL008.tencent.com
Whole thread Raw
List pgsql-hackers

Hi hackers:

         When using pg_stat_statements to collect running SQL of PG, we find it is hard for our program to get exact operation type of the SQL,  such as SELECT, DELETE, UPDATE, INSERT, and so on.

   So we modify the the source code of pg_stat_statements and add another output parameter to tell us the operation type.

Of course some application know their operation type, but for us and many public databases, doing this is hard.

The only way is to reparse the SQL, obviously it is too expensive for a monitoring or diagnosis system.

We have done the job and are willing to post a patch.

 

jasonysli

 

 

pgsql-hackers by date:

Previous
From: Devrim Gündüz
Date:
Subject: Re: [HACKERS] drop support for Python 2.3
Next
From: Robert Haas
Date:
Subject: Re: [HACKERS] Instability in select_parallel regression test