Skip site navigation (1) Skip section navigation (2)

Strange CREATE VIEW behavior??

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: Strange CREATE VIEW behavior??
Date: 2001-06-14 06:01:51
Message-ID: 200106140601.f5E61p213317@hub.org (view raw or flat)
Thread:
Lists: pgsql-bugs
Basil A. Evseenko (evseenko(at)msiu(dot)ru) reports a bug with a severity of 3
The lower the number the more severe it is.

Short Description
Strange CREATE VIEW behavior??

Long Description
createdb test
psql test

test=# create table zz(ss int, ff varchar);
test=# create view ff2 as select ff as user, ss as num from zz;
test=# create view ff3 as select ff as user1, ss as num from zz;
test=# \d ff2
               View "ff2"
 Attribute |       Type        | Modifier
-----------+-------------------+----------
 user      | character varying |
 num       | integer           |
View definition: SELECT zz.ff AS "user", zz.ss AS num FROM zz;

test=# \d ff3
                View "ff3"
 Attribute |       Type        | Modifier
-----------+-------------------+----------
 user1     | character varying |
 num       | integer           |
View definition: SELECT zz.ff AS user1, zz.ss AS num FROM zz;

Why in the first case column has name "user" (with '"') ?

PostgreSQL 7.1.2 builded gcc 2.95.3 with options:
./configure  --prefix=/usr --sysconfdir=/etc --enable-locale --enable-multibyte=KOI8 --enable-unicode-conversion
--with-tcl --with-perl --with-python --with-openssl --with-CXX --with-gnu-ld --enable-syslog

Linux-2.2.19 on i686, glibc-2.1.3

Sample Code


No file was uploaded with this report


Responses

pgsql-bugs by date

Next:From: Mister XDate: 2001-06-14 06:06:42
Subject: ODBC Interface version 07_01_0005, problem with C++ exceptions
Previous:From: Steve McClureDate: 2001-06-13 21:26:57
Subject: PostgreSQL problem

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group