SELECT LOG10(3); // Output is 0.477121254719662
SELECT LOG10(0.1); // Output is -1
SELECT LOG10(0); // Output is NULL
SELECT ROUND(LOG10(2),2);// Output is 0.30
SELECT ROUND(LOG10(-2),2); // Output is NULL
SELECT ROUND(LOG10(7),2); // Output is 0.85
SELECT LOG10( X )
Returns natural logarithm of X with base 10. When X is less than or equal to 0.0E0 we get NULL as output.
Author
🎥 Join me live on YouTubePassionate about coding and teaching, I publish practical tutorials on PHP, Python, JavaScript, SQL, and web development. My goal is to make learning simple, engaging, and project‑oriented with real examples and source code.