Re: Converting char to varchar automatically - Mailing list pgsql-general

From Andrus
Subject Re: Converting char to varchar automatically
Date
Msg-id 5487F147B00848D69371EB3A4026DE35@dell2
Whole thread Raw
In response to Re: Converting char to varchar automatically  (Melvin Davidson <melvin6925@gmail.com>)
List pgsql-general
Hi!
>SELECT 'ALTER TABLE ' || quote_ident(n.nspname) || '.' ||  quote_ident(c.relname)
>       || ' ALTER COLUMN ' || quote_ident(a.attname) || ' TYPE varchar;'
>  FROM pg_class c
>  JOIN pg_namespace n ON n.oid = c.relnamespace
>  JOIN pg_attribute a ON a.attrelid = c.oid
>  JOIN pg_type t ON t.oid = a.atttypid
> WHERE t.typname = 'char'
>   AND n.nspname <> 'pg_catalog';
It does not return any data.
 
Andrus.
 

pgsql-general by date:

Previous
From: Igor Neyman
Date:
Subject: Re: How to get good performance for very large lists/sets?
Next
From: Andy Colson
Date:
Subject: Re: How to get good performance for very large lists/sets?