I have a field which store messages and I want to get how many Gb's this message is consuming. For example message: "Hi how are you?" So I want to convert this string in Gb's
To get the size of the string in gigabytes, you can use:
SELECT LENGTHB( 'Hi how are you?' ) / POWER( 2, 30 ) AS size_in_gigabytes
FROM DUAL;
Which outputs:
SIZE_IN_GIGABYTES .000000013969838619232177734375
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.