Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

As the title says, I'm wondering what is this command and why am I seeing a large amount of this query on my database? It's currently 13.30% of my total queries. I've tried googling this but there's not really any documentation on the subject.

Here's a part of the report done by mysqlreport:

__ Questions ___________________________________________________________
Total          17.43M     7.5/s
  DMS           8.58M     3.7/s  %Total:  49.23
  QC Hits       3.91M     1.7/s           22.42
  Com_          2.54M     1.1/s           14.54
  COM_QUIT      2.48M     1.1/s           14.21
  -Unknown     68.28k     0.0/s            0.39
Slow 10 s          17     0.0/s            0.00  %DMS:   0.00  Log:  ON
DMS             8.58M     3.7/s           49.23
  SELECT        6.05M     2.6/s           34.71         70.51
  INSERT        1.36M     0.6/s            7.80         15.85
  UPDATE        1.15M     0.5/s            6.60         13.40
  DELETE       20.35k     0.0/s            0.12          0.24
  REPLACE          61     0.0/s            0.00          0.00
Com_            2.54M     1.1/s           14.54
  set_option    2.32M     1.0/s           13.30
  show_proces  83.16k     0.0/s            0.48
  create_tabl  60.20k     0.0/s            0.35
share|improve this question

2 Answers 2

up vote 3 down vote accepted

It probably means that you ran a lot of commands that start with "SET something = somethingelse;"

I would say to set your general_log on for a short while on your dev environment and search for SET commands. It would probably be something to do with setting the server time.

http://dev.mysql.com/doc/refman/5.5/en/server-status-variables.html#statvar_Com_xxx

share|improve this answer
    
Thanks, figured out this was because of SET NAMES utf8. –  onik Sep 14 '11 at 8:13
    
Actually COM_SET_OPTION is used exclusively for multi-statement support as explained here. SET commands issued by clients are just sent as regular queries, so something like SET NAMES utf8 would not generate a COM_SET_OPTION packet. –  Michael Mior 2 days ago

COM_SET_OPTION is a special command in the MySQL protocol which is currently used exclusively to enable or disable multi-statement support as detailed here. Some database clients (such as certain versions of the MySQL libraries for PHP) will do this every time a new connection is established.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.