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 1iuzIi-0004vB-S1 for pgsql-general@arkaria.postgresql.org; Fri, 24 Jan 2020 13:47:09 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iuzIh-0003Cy-MB for pgsql-general@arkaria.postgresql.org; Fri, 24 Jan 2020 13:47:07 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iuzIh-0003Ca-9G for pgsql-general@lists.postgresql.org; Fri, 24 Jan 2020 13:47:07 +0000 Received: from mail-wr1-x442.google.com ([2a00:1450:4864:20::442]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1iuzIc-0006Au-C1 for pgsql-general@lists.postgresql.org; Fri, 24 Jan 2020 13:47:06 +0000 Received: by mail-wr1-x442.google.com with SMTP id z7so2019016wrl.13 for ; Fri, 24 Jan 2020 05:47:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:date:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=NVF0uMQLFWUoOKUKObChdHVVEUjAYaAe8GhXR4VjE4E=; b=dyIQR+Hz1ne3+ohkhSBCm9aNO1DnJfuMIBoZnEHMEbxf6X13PDrIaYlzXN4469O9G9 P48R33z/xnmfr/f/93EabcAfuRBt7IlFD8jAlOkxd6YLMU0lZX86a+c8qf/JcMO3Na/C 0egAPIUbA+EhDkdP3skfCGJjZkEU/LHRb69KEDPvmKat01087750SZVWGybcRBRilNu5 IGr02nbRwFr9tUp7FV9spfASZsmhlyMa+LLY7wyhMlPN/YaBDpGG5u2C5JAlI0i7vLGh UAEE6fRBZ8g7dmMaLrnXBrxBiA2HIU+iTpX9+fdf4emj7LrpoVfasMx7U/X50MR/LCu+ gIeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=NVF0uMQLFWUoOKUKObChdHVVEUjAYaAe8GhXR4VjE4E=; b=QzlvuAlSvqqZm+E4FtWxJrquoCW/zq5ZjAV62fzi9p1u7Klz1OiouIAacmfHGzjy5Y Go9EplClHKPypCuLJBSwyBhdwkuBMR8Al8nHCYthsw+ZQpKWsZLV/BwN2HKAS6Ie/8dR s4lYv4F8w9WWX4juPGW3wfM7SriDJNAhWmatbFBOchbM4YuLv8srKLNSGWmw2onDC1Zg HrDKs457j4kx96IVwZPnhn965km1NOVtQfBk96Ie9FKc0QzM5W3A+3o/KKMyGZAPl6y6 ghp1dQlPLMTDZxWIUjSkDQTxqPjuWgxpmvHFlMdPnDHTTMAg/3658wQTiP58aFX7w37q KLiA== X-Gm-Message-State: APjAAAVKNKVlIdfPyYojODsHnBZs9ODIb68LGOT/heS6eRdeHNIQWT3l ngFHBWS9NzjjzkEvwNAkplXekCvi+ZQ= X-Google-Smtp-Source: APXvYqz0gHAFGjMWwK9DqXcZwquUalFMuEv49R2NQCHvxT+FJDHmpl4dqdr7PXVrG5T5lfLSJ++i6Q== X-Received: by 2002:a5d:49c7:: with SMTP id t7mr4307484wrs.369.1579873619504; Fri, 24 Jan 2020 05:46:59 -0800 (PST) Received: from localhost.localdomain (217-149-170-234.nat.highway.telekom.at. [217.149.170.234]) by smtp.gmail.com with ESMTPSA id m21sm6847507wmi.27.2020.01.24.05.46.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Jan 2020 05:46:59 -0800 (PST) Message-ID: <930f256d79d92d07db9dd9f7415f688c35631025.camel@cybertec.at> Subject: Re: Does converting an indexed varchar to text rewrite its index? Docs say so, tests say no. From: Laurenz Albe To: Mike Lissner , pgsql-general@lists.postgresql.org Date: Fri, 24 Jan 2020 14:46:58 +0100 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.32.5 (3.32.5-1.fc30) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Thu, 2020-01-23 at 08:55 -0800, Mike Lissner wrote: > I think the docs say that if you convert a varchar to text, it'll rewrite the index, > but my test doesn't seem to indicate that. Is the test or the documentation wrong? > > If the docs, I'll be happy to make a fix my first contribution to postgresql. :) > > Here are the docs: > > (https://www.postgresql.org/docs/10/sql-altertable.html) We'd be happy about a documentation patch. Yours, Laurenz Albe -- Cybertec | https://www.cybertec-postgresql.com