Re: OID out of range

2020-01-15 Thread Rob Sargent
> On Jan 15, 2020, at 12:17 PM, Konireddy Rajashekar > wrote: > > @Alvaro Herrera, Can i alter the datatype of relid to oid and try ? > Not if Alvaro’s theory is correct. List that column, check for nulls, values greater the 2^32.

Re: OID out of range

2020-01-15 Thread David G. Johnston
Please don't top-post here. On Wed, Jan 15, 2020 at 12:01 PM Konireddy Rajashekar < rajkonire...@gmail.com> wrote: > tried casting to text,varchar but no luck > select u.relid,c.relnamespace::regnamespace::text,c.relname,now() as > current_time,pg_size_pretty(pg_relation_size(c.oid)) as > curren

Re: OID out of range

2020-01-15 Thread Konireddy Rajashekar
@Alvaro Herrera, Can i alter the datatype of relid to oid and try ? On Thu, Jan 16, 2020 at 12:41 AM Alvaro Herrera wrote: > On 2020-Jan-15, Konireddy Rajashekar wrote: > > > rangetest-# \d user_tables_sizes > > Table "user_tables_sizes" > >Column|Type

Re: OID out of range

2020-01-15 Thread Alvaro Herrera
On 2020-Jan-15, Konireddy Rajashekar wrote: > rangetest-# \d user_tables_sizes > Table "user_tables_sizes" >Column|Type | Collation | Nullable | Default > -+-+---+--+- > relid

Re: OID out of range

2020-01-15 Thread Konireddy Rajashekar
tried casting to text,varchar but no luck select u.relid,c.relnamespace::regnamespace::text,c.relname,now() as current_time,pg_size_pretty(pg_relation_size(c.oid)) as current_size,pg_size_pretty(u.table_size) as previous_size,pg_size_pretty(pg_relation_size(c.oid) - pg_relation_size(u.table_size))

Re: OID out of range

2020-01-15 Thread David G. Johnston
On Wed, Jan 15, 2020 at 11:36 AM bhargav kamineni wrote: > Any workaround to make it work ? > Convert both to text and join on that? Curious choice making relid numeric... David J.

Re: OID out of range

2020-01-15 Thread bhargav kamineni
Any workaround to make it work ? On Thu, 16 Jan 2020 at 00:00, Adrian Klaver wrote: > On 1/15/20 10:18 AM, Konireddy Rajashekar wrote: > > I am getting ERROR: OID out of range while firing below SQL , what could > > be the reason? I am joining pg_class and one user_created table to > > compare t

Re: OID out of range

2020-01-15 Thread Adrian Klaver
On 1/15/20 10:18 AM, Konireddy Rajashekar wrote: I am getting ERROR: OID out of range while firing below SQL , what could be the reason? I am joining pg_class and one user_created table to compare tables size. select u.relid,c.relnamespace::regnamespace::text,c.relname,now() as current_time,