arrow-left

All pages
gitbookPowered by GitBook
1 of 1

Loading...

UNCOMPRESSED_LENGTH

Return length of uncompressed string. This function returns the length of a compressed string before it was compressed.

hashtag
Syntax

UNCOMPRESSED_LENGTH(compressed_string)

hashtag
Description

Returns the length that the compressed string had before being compressed with .

UNCOMPRESSED_LENGTH() returns NULL or an incorrect result if the string is not compressed.

Returns MYSQL_TYPE_LONG, or , if the result fits within 32-bits.

hashtag
Examples

This page is licensed: GPLv2, originally from

COMPRESS()
int(10)
fill_help_tables.sqlarrow-up-right
spinner
SELECT UNCOMPRESSED_LENGTH(COMPRESS(REPEAT('a',30)));
+-----------------------------------------------+
| UNCOMPRESSED_LENGTH(COMPRESS(REPEAT('a',30))) |
+-----------------------------------------------+
|                                            30 |
+-----------------------------------------------+