Search Postgresql Archives

Re: alter column appears to work, but doesn't?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Monday, September 05, 2011 1:48:58 pm Ron Peterson wrote:
> 2011-09-05_16:14:00-0400 Tom Lane <tgl@xxxxxxxxxxxxx>:
> > Ron Peterson <rpeterso@xxxxxxxxxxxxx> writes:
> > > I just dropped my logging rules, stopped the database and restarted it,
> > > put my rules back in place, and now it works.  Not sure why.  Cached
> > > query plan?
> > 
> > Maybe.  We'd need a reproducible test case to do more than speculate
> > though.
> 
> Hi Tom,
> 
> I was able to reproduce this.  DDL below.  Probably more DDL than
> necessary, but not sure what is or isn't relevant.
> 
> postgres=# drop rule attribute_insert_rule on attributes;
> postgres=# drop rule attribute_update_rule on attributes;
> postgres=# drop rule attribute_delete_rule on attributes;
> postgres=# alter table attributes_log alter column attribute_name type
> varchar(50); ...then recreate rules below
> postgres=# insert into attributes values ( repeat( 'x', 49 ) );
> ERROR:  value too long for type character varying(48)
> 
> 

I am not seeing where you change the varchar length in the table attributes. 
That is where the error is coming from.

-- 
Adrian Klaver
adrian.klaver@xxxxxxxxx

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux