Re: custom function for converting human readable sizes to bytes - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: custom function for converting human readable sizes to bytes
Date
Msg-id 5651FBBB.4070505@BlueTreble.com
Whole thread Raw
In response to custom function for converting human readable sizes to bytes  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: custom function for converting human readable sizes to bytes  (Pavel Stehule <pavel.stehule@gmail.com>)
Re: custom function for converting human readable sizes to bytes  (Marko Tiikkaja <marko@joh.to>)
List pgsql-hackers
On 11/21/15 12:49 AM, Pavel Stehule wrote:
>
> I propose inversion function to pg_size_pretty function - like
> pg_human_size.
>
> Usage:
>
> SELECT * FROM pg_class
>    WHERE pg_table_size(oid) > pg_human_size('2GB');

I'm not a big fan of the name, but +1 on the general idea.

Maybe pg_size_pretty(text)?
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com



pgsql-hackers by date:

Previous
From: Jim Nasby
Date:
Subject: Re: count_nulls(VARIADIC "any")
Next
From: Marko Tiikkaja
Date:
Subject: Re: count_nulls(VARIADIC "any")