bugl
bugl
HomeLearnPatternsPathsSearchPremium
HomeLearnPatternsPaths

Loading lesson path

Learn/SQL/SQL References
SQL•SQL References

MySQL LOG2() Function

Example

SELECT LOG2(6);

Definition and Usage

The LOG2() function returns the natural logarithm of a number to base-2.

Note

See also the LOG() function.

Syntax

LOG2(
number
)

Parameter Values

ParameterDescription
numberA number. Must be greater than 0

Technical Details

Works in:From MySQL 4.0

Previous

MySQL LOG10() Function

Next

MySQL MAX() Function