Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iCNNR-0003OS-5c for pgsql-general@arkaria.postgresql.org; Mon, 23 Sep 2019 12:23:37 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iCNNP-0004c5-TD for pgsql-general@arkaria.postgresql.org; Mon, 23 Sep 2019 12:23:35 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iCNNP-0004bl-Gv for pgsql-general@lists.postgresql.org; Mon, 23 Sep 2019 12:23:35 +0000 Received: from mail-ot1-x342.google.com ([2607:f8b0:4864:20::342]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iCNNM-0002je-UG for pgsql-general@lists.postgresql.org; Mon, 23 Sep 2019 12:23:34 +0000 Received: by mail-ot1-x342.google.com with SMTP id g13so11868914otp.8 for ; Mon, 23 Sep 2019 05:23:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding:content-language; bh=ivEHamfnqrBe+x2agM19Y/be4db6T4Fs1mH5RtzWzKk=; b=U2BRLL4An0PLBoIUUNkSln3gzoVQmZqVAeiyf3D9C7ELhlBPj5G2O73j3gnHLMVI3Q eL5J5E48uDGehcHpJOBfWuNzyNL5RClJXTPa2cAx1et42xkowwuaxOPNP/AtAVnIkPVg BdncvwIzIo19CrPY/aLK7wMoC1VyI9KilX5ssmtsmbSoTX4oQHpfJWozl9aKSMNZOboK WcwlcKtOUx61y8s0sXFIMn2uvddS0IDB06BOGfwChAoFeawto0D+3j5Pr+nkOwLJvDTK 9l/ylAtsek+JHsHVfWgRVTIrbNaArU4ryhaRl4TL1/VhIzWaDMgi3lUSSS1IC4zmj/c6 +8nA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=ivEHamfnqrBe+x2agM19Y/be4db6T4Fs1mH5RtzWzKk=; b=Wa7V5garH2c2r++36ITpCGKK2UDo6VN+/uqQsSXVVAni6+kMo9vfJ53NljZMLjscjp c2lCxc4+8QiY1RA8JYFlWfR6NiCsJ1rJImUp3k/YOSL0G7TFdV8jC2r06eSuR/hHiQfY 5wvTJ/myo6Qsm924RMAaoHBhczXTB+3JKtLjEwDmKz2xPjtcR5G4IasOhQy/hXSj0vxZ R70+6wJvlVbanPCUOVGvXpFDTEc7XYUDGwkn3GFwBL3B35a6NrV+Nmofy4JtWlI1djG4 gWVcjyjmVALY+1oLzvcqkLKS1dCQlwDFNY+TyIGoQRvamyt6sD13e+gHwGBb4eYtjSfS VaRA== X-Gm-Message-State: APjAAAWgWnBEf8dgysWXKYVAxnyaBSGQRImpCcGmUYkDXxawNjtXvo76 s+N2pfpDRDsoMqCW0A9yLi9lFSbMw8Q= X-Google-Smtp-Source: APXvYqzOsmKvVsqufLik+0ZK7QxuZ61/49el2uqLkY51StgTvgglEUZKXRoJ4jgAG0DcnPAytLAR9w== X-Received: by 2002:a9d:3463:: with SMTP id v90mr22461834otb.29.1569241409665; Mon, 23 Sep 2019 05:23:29 -0700 (PDT) Received: from [192.168.1.10] (ip70-186-126-197.no.no.cox.net. [70.186.126.197]) by smtp.googlemail.com with ESMTPSA id l4sm3598781otj.64.2019.09.23.05.23.28 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Sep 2019 05:23:28 -0700 (PDT) Subject: Re: unable to drop index because it does not exists To: pgsql-general@lists.postgresql.org References: From: Ron Message-ID: <63949fa8-8032-2773-a06e-47736a33012a@gmail.com> Date: Mon, 23 Sep 2019 07:23:27 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 9/23/19 6:39 AM, Luca Ferrari wrote: > Hi, > running 11.5 I've got a partitioned table where I want to destroy an > index (on a column that has nothing to do with the partition): > > > respidb=# \d+ respi.root > > Column | Type | > --------------+-----------------------------+- > sen_id | integer | > mis_flusso | integer | > mis_tasso | integer | > mis_velocita | integer | > mis_ora | timestamp without time zone | > pk | bigint | > ts | timestamp without time zone | > Partition key: LIST (date_part('year'::text, mis_ora)) > Indexes: > "idx_root_sensore" btree (sen_id) > "idx_ts" btree (ts) > Partitions: respi.y2018 FOR VALUES IN ('2018'), PARTITIONED, > respi.y2019 FOR VALUES IN ('2019'), PARTITIONED, > respi.y2020 FOR VALUES IN ('2020'), PARTITIONED > > respidb=# drop index idx_root_sensore; > ERROR: index "idx_root_sensore" does not exist > > Of course the index exists: > > SELECT oid, relname, relkind FROM pg_class WHERE relname = 'idx_root_sensore'; > -[ RECORD 1 ]------------- > oid | 40950 > relname | idx_root_sensore > relkind | I > > > I already did a manual vacuum on the table. > Any idea? Try specifying the schema name: drop index respi.idx_root_sensore; -- Angular momentum makes the world go 'round.