MySQL CRC32() checksum

CRC32(expr) computes a cyclic redundancy check and returns a 32-bit unsigned value. The result is NULL when the argument is NULL.

SELECT CRC32('string');
SELECT CRC32('plus2net'); -- Output: 930124482
SELECT CRC32(NULL); -- Output: NULL

Column structure for stored CRC32 values

If you store CRC32 output in MySQL, use an unsigned integer type capable of holding the full 32-bit unsigned range.

PHP crc32()

PHP also provides crc32(). The following example calculates the checksum of the same string.

<?php
echo crc32('plus2net');
?>

On common 64-bit PHP builds the output for this example is 930124482.




Subscribe to our YouTube Channel here



plus2net.com




SQL Video Tutorials










✖
We use cookies to improve your browsing experience. . Learn more
HTML MySQL PHP JavaScript ASP Photoshop Articles Contact us
© 2000-2026 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer