sql - Custom aggregate functions -


How does one collect a custom in SQL Server 2012? I am trying to get an average total.

Something like this:

 ; With CT (select the top 50 percent of the tablet by the Vel Dell) select the top 1 CT    

you should just use the built-in function, percentile_cont () or percentil_disc () (see), how you define the median for any number of records Depends on what it does.

I think the following is what you want:

  Choose percentile_cont (0.5) within the group (sorted by the wall) in the form of TBL in the middle;   

This is very easy to define your own function.

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -