WIDTH_BUCKET() Function in Oracle

In Oracle, the WIDTH_BUCKET() function allows you to construct equiwidth histograms, in which the histogram range is divided into intervals that have identical size.

For a given expression, WIDTH_BUCKET() returns the bucket number into which the value of this expression would fall after being evaluated.

Read more

NANVL() Function in Oracle

In Oracle, the NANVL() function allows us to deal with NaN values by specifying another number to return in its place.

The way it works is, it accepts two arguments. If the first argument is NaN (not a number), it returns the second argument. If the first argument is a number, then it simply returns that number.

Note that this function is useful only for floating-point numbers of type BINARY_FLOAT or BINARY_DOUBLE.

Read more

REPLACE() Function in Oracle

In Oracle, the REPLACE() function allows you to replace a part of a string with another string.

The function accepts three arguments: the string, the substring to replace, and the replacement string (to replace the substring with).

You can omit the replacement string, in which case, the function will remove all instances of the substring.

Read more