Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cOW6I-0004WM-7n for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Jan 2017 20:54:30 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1cOW6H-0003jS-HQ for pgsql-hackers@arkaria.postgresql.org; Tue, 03 Jan 2017 20:54:29 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1cOW6H-0003jM-1a for pgsql-hackers@postgresql.org; Tue, 03 Jan 2017 20:54:29 +0000 Received: from mail-io0-x233.google.com ([2607:f8b0:4001:c06::233]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1cOW6D-0005Xr-G2 for pgsql-hackers@postgresql.org; Tue, 03 Jan 2017 20:54:27 +0000 Received: by mail-io0-x233.google.com with SMTP id h133so202899628ioe.3 for ; Tue, 03 Jan 2017 12:54:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=NXaU0D3r8xWUDKZF5nIP7RX7LNbsj5GJt4VigOy634c=; b=jRMJiIPWjYBLLShYq0BZOi4dv4OdhaaZcH9MYnJJ70QZ3juTbEnngKKpTpOx8CzxBo BF1x+MlFoNCWXWUDubDGC9bUZ/B11APNfG9vCTodgU3ZoyMWfISDlgO52xH8Qlh/5HJ2 tfbi8GdaL4cFkZDOL0STdBO4NtxvkwTcnpLNPB0OyuHgDHdNUtbwLgFMs+PiUcelF5BF kkDGD2IRVeUYPMytXeD9uIWwkrylN6hwvG4uK0ASZJHkO425X60OMZ6P7djo/Z6hXTFZ RbWgZTphJiz0Bkd0NtqGgtFJPPyYHsO1NtP+MvQ3XTVM3jiyihEHbz1N3UHi8VNInRDW PkxQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=NXaU0D3r8xWUDKZF5nIP7RX7LNbsj5GJt4VigOy634c=; b=JmrkHwnUZDu+RDsst+FR9kWheKvKJd61jkY01HY/gFBYALhXwp+jlrk/viMOycdGvx 1Mo6DUY+iObTBwRYg6/Ttij7N3MfcSeR9QkauLkszjNnTYFe4DI9gP9NZ66f0xr2RgIT 24UAnzlgkcfuC2EQ5EJRdUEfjewKflw6ZqRJYL+9V+h9cecTiVKkkyVyusPvE9eKLSxx 5K5qvfgys/MVnIEFKYdOtGtpFNfrEoGzixhXcLpV4GBEoIL6eNWX/ByDkdB6i2yE3YpM hMp0qQXmG6RAipN4Cb4xUMzjJlG/2nBB7FYy+IssWUX6v2E0h0iBqRpZppoJ0eBJKPio qdFg== X-Gm-Message-State: AIkVDXK1MbeaVfVLafzgLyStLJt3Vw5fGsi8W79ft+oTeBJOxs7xEOkTTVHG252krjRAXg== X-Received: by 10.107.151.198 with SMTP id z189mr46276027iod.181.1483476864499; Tue, 03 Jan 2017 12:54:24 -0800 (PST) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id y125sm32860693ity.13.2017.01.03.12.54.23 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 03 Jan 2017 12:54:24 -0800 (PST) Received: by pryzbyj (Postfix, from userid 1000) id 3B31D8014DD; Tue, 3 Jan 2017 14:54:23 -0600 (CST) Date: Tue, 3 Jan 2017 14:54:23 -0600 From: Justin Pryzby To: Tom Lane Cc: Robert Haas , "pgsql-hackers@postgresql.org" Subject: Re: ALTER TABLE .. ALTER COLUMN .. ERROR: attribute .. has wrong type Message-ID: <20170103205423.GW32031@telsasoft.com> References: <20170103165903.GP32031@telsasoft.com> <20170103185742.GQ32031@telsasoft.com> <28476.1483471956@sss.pgh.pa.us> <20170103194604.GR32031@telsasoft.com> <29101.1483473021@sss.pgh.pa.us> <20170103195709.GT32031@telsasoft.com> <30539.1483474695@sss.pgh.pa.us> <20170103202919.GU32031@telsasoft.com> <31170.1483475734@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <31170.1483475734@sss.pgh.pa.us> User-Agent: Mutt/1.5.23 (2014-03-12) X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On Tue, Jan 03, 2017 at 03:35:34PM -0500, Tom Lane wrote: > Justin Pryzby writes: > > On Tue, Jan 03, 2017 at 03:18:15PM -0500, Tom Lane wrote: > >> I'm wondering if this represents some sort of out-of-sync condition > >> between the table and its child tables. We can't actually tell from > >> this trace which table is being processed. Could you try, from this > >> breakpoint, > >> > >> f 3 > >> p oldrel->rd_rel->relname > > > (gdb) p oldrel->rd_rel->relname > > $1 = {data = "eric_umts_rnc_utrancell_201701", '\000' } > > Right. So I bet that if you check the attnum of pmsumpacketlatency_000 in > eric_umts_rnc_utrancell_metrics, you'll find it's different from that in > eric_umts_rnc_utrancell_201701, and that the attribute having that attnum > in eric_umts_rnc_utrancell_201701 has type smallint not int. I think that's consistent with what your understanding: ts=# SELECT attrelid::regclass, attname, attnum, atttypid FROM pg_attribute WHERE attrelid::regclass::text~'eric_umts_rnc_utrancell_(metrics|201701)$' AND (attname='pmsumpacketlatency_000' OR attnum IN (367,424) ) ORDER BY 1,2; eric_umts_rnc_utrancell_metrics | pmsamplespshsadchrabestablish | 367 | 21 eric_umts_rnc_utrancell_metrics | pmsumpacketlatency_000 | 424 | 23 eric_umts_rnc_utrancell_201701 | pmsumpacketlatency_000 | 367 | 23 eric_umts_rnc_utrancell_201701 | pmulupswitchsuccessmedium | 424 | 21 Justin -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers