Re: [GENERAL] Some issues about data type convert

2010-01-04 Thread donniehan
>> Um, I think the OP is right. Notice he does: ... >> showing that PG is auto-magically inserting a cast from BIGINT to OID. >>I think the OP is either expecting the CREATE VIEW to fail saying types >>are invalid, or to result in "c1" being cast to BIGINT Yes, that's what i mean. Is that more r

[GENERAL] Some issues about data type convert

2010-01-04 Thread donniehan
Hi guys, I have a question about pg_cast--- data type convert. Pg provide more data types than sql spec, such as OID. Internal OID type is unsigned int32 and INT8 is int64. Why pg can convert INT8 into OID implicitly while can not convert OID into INT8 implicitly? There may be some pr

Re: [GENERAL] Why grantor is owner in this case?

2009-12-27 Thread donniehan
Thank you very much ! Regards -Dongni "Tom Lane" news:4759.1261758...@sss.pgh.pa.us... > "donniehan" writes: >> I have a question about the grantor. Why the grantor is owner in the >> following case ? I think it should be postgres(dba). > > Gra

Re: [GENERAL] Why grantor is owner in this case?

2009-12-27 Thread donniehan
59.1261758...@sss.pgh.pa.us... > "donniehan" writes: >> I have a question about the grantor. Why the grantor is owner in the >> following case ? I think it should be postgres(dba). > > Grants done by a superuser on an object he doesn't own are treat

[GENERAL] Why grantor is owner in this case?

2009-12-25 Thread donniehan
Hi guys, I have a question about the grantor. Why the grantor is owner in the following case ? I think it should be postgres(dba). postgres=# create user u1; CREATE ROLE postgres=# create user u2; CREATE ROLE postgres=# set session authorization u1; SET postgres=> create table u1_tb1(a int); C