Getting Started with Adobe After Effects - Part 6: Motion Blur


Upload Image Close it
Select File

Browse by Tags · View All
SQL Server 119
#SQLServer 88
Oracle 70
#SQL SERVER 35
BRH 31
SQL Server 2012 29
denali 23
#TSQL 19
TSQL 19
C# 15

Archive · View All
October 2011 31
November 2011 30
September 2011 30
August 2011 18
December 2011 15
July 2011 13
June 2011 8
May 2012 4
April 2012 3
January 2010 3

Day 11: Width_Bucket function in Oracle

Sep 24 2011 11:12PM by Niladri Biswas   

Let Us Learn Oracle - Part 11 of N [ Width_Bucket function in Oracle ]

Source table: tblPlayers

Syntax: Width_Bucket(Expression, Minimum,Maximum,Number)

Purpose: This function divides a given data set into buckets with an equal interval size.

e.g. Marks = 35-59, 60-74, 75-89, 99-100

It is also known as 'equiwidth histogram'. The histogram range is divided into intervals that have identical size.It is like Ntile function which generates equiheight histograms.

SQL> Select PlayerID,BelongsTO,Width_Bucket(Sum(FeePerMatch),100,5000,10) Bucket From tblplayers Group By PlayerID,BelongsTO Order By PlayerID;

  PLAYERID BELONGSTO      BUCKET
---------- ---------- ----------
         1 India               4
         2 India               2
         3 India               6
         4 India               1
         5 India              11
         6 USA                11
         7 USA                 2
         8 USA                11
         9 USA                11
        10 USA                11

10 rows selected.

Thanks for reading.

Tags: #SQLServer, SQL Server, Oracle,


Niladri Biswas
7 · 21% · 6710
1
 
0
Lifesaver
 
0
Refreshed
 
0
Learned
 
0
Incorrect



Submit

1  Comments  

  • Hi Niladri,

    Adding "sum(FeesPerMatch)" column in result set helps in understanding this function more... Can you add that column also to result set. so it will help in analyzing the function.

    commented on Oct 3 2011 11:05PM
    Ramireddy
    2 · 41% · 12972

Your Comment


Sign Up or Login to post a comment.

"Day 11: Width_Bucket function in Oracle" rated 5 out of 5 by 1 readers
Day 11: Width_Bucket function in Oracle , 5.0 out of 5 based on 1 ratings
    Copyright © Rivera Informatic Private Ltd Contact us      Privacy Policy      Terms of use      Report Abuse      Advertising      [ZULU1097]