Home > database >  The median mysql for help
The median mysql for help

Time:10-27

Now has built a table zysj, serial number, want to take out the time that a list of the median, should how to write?

CodePudding user response:

Select avg (time) from zysj
Where sn in (floor ((Max (sn) + min (sn))/2), ceil ((Max (sn) + min (sn))/2));
  • Related