Обсуждение: character varying and varchar

Поиск
Список
Период
Сортировка

character varying and varchar

От
novnov
Дата:
When 1.6 seems to have dropped varchar in favor of character varying.
Shouldn't this be an option as opposed to an enforced behavior? I've read a
little on the list about the change, but the problem is some packages I'm
working with don't recognize character varying. Maybe that will change over
time but in the meantime it's a change that does not help.

It's kind of weird too - if I create a varchar field with pgAdmin III 1.4.2
(windows), it's reported as varchar, including the ALTER TABLE statements
for the col; but if I view the same table in pgAdmin 1.6, it's reported as
character varying, even in the SQL?
-- 
View this message in context: http://www.nabble.com/character-varying-and-varchar-tf2749281.html#a7670566
Sent from the PostgreSQL - pgadmin support mailing list archive at Nabble.com.



Re: character varying and varchar

От
Dave Page
Дата:
novnov wrote:
> When 1.6 seems to have dropped varchar in favor of character varying.
> Shouldn't this be an option as opposed to an enforced behavior? I've read a
> little on the list about the change, but the problem is some packages I'm
> working with don't recognize character varying. Maybe that will change over
> time but in the meantime it's a change that does not help.
> 
> It's kind of weird too - if I create a varchar field with pgAdmin III 1.4.2
> (windows), it's reported as varchar, including the ALTER TABLE statements
> for the col; but if I view the same table in pgAdmin 1.6, it's reported as
> character varying, even in the SQL?

They are *exactly* the same type on the server, we just use the SQL spec 
compliant name now inline with psql and pg_dump etc.

I fail to see how your other packages can complain about the change 
given that pgAdmin is only an administration front end, and what they 
see on the server is no different than what is was when you used an 
older version of pgAdmin.

Regards, Dave.


Re: character varying and varchar

От
novnov
Дата:

novnov wrote:
> When 1.6 seems to have dropped varchar in favor of character varying.
> Shouldn't this be an option as opposed to an enforced behavior? I've read
> a
> little on the list about the change, but the problem is some packages I'm
> working with don't recognize character varying. Maybe that will change
> over
> time but in the meantime it's a change that does not help.
> 
> It's kind of weird too - if I create a varchar field with pgAdmin III
> 1.4.2
> (windows), it's reported as varchar, including the ALTER TABLE statements
> for the col; but if I view the same table in pgAdmin 1.6, it's reported as
> character varying, even in the SQL?

They are *exactly* the same type on the server, we just use the SQL spec 
compliant name now inline with psql and pg_dump etc.

I fail to see how your other packages can complain about the change 
given that pgAdmin is only an administration front end, and what they 
see on the server is no different than what is was when you used an 
older version of pgAdmin.

Regards, Dave.

It seems you're right, in all of my 7 or so tests I was seeing a
'disturbance in the force' that seemed to have a 1:1 correlation to the
nametype, but it turned out to be coincidental.



-- 
View this message in context: http://www.nabble.com/character-varying-and-varchar-tf2749281.html#a7687281
Sent from the PostgreSQL - pgadmin support mailing list archive at Nabble.com.



Re: character varying and varchar

От
Dave Page
Дата:
novnov wrote:

> It seems you're right, in all of my 7 or so tests I was seeing a
> 'disturbance in the force' that seemed to have a 1:1 correlation to the
> nametype, but it turned out to be coincidental.

:-)

Yeah, the force can be unpredictable at times.

Regards, Dave.