[v15] ALTER TABLE ... SET ACCESS METHOD

Started by Jeff Davisover 5 years ago4 messageshackers
Beta feature

Hackorum builds and tests every patch posted to the lists, not only commitfest submissions. This is Hackorum's own CI rather than the PostgreSQL project's, and it is still under testing - please report anything that looks wrong.

won't retrysuccessCI history

You can run a PostgreSQL built from this patch straight from Docker, with no checkout and no build:

docker run --rm -p 5432:5432 ghcr.io/hackorum-dev/postgres-patch:t44170
psql -h localhost -U postgres

Built from patchset v1 (message #1), July 27, 2026 at 05:06 PM.

Every patchset is also pushed to a branch of our PostgreSQL fork, so you can check out the same tree CI built. Without a PostgreSQL checkout:

git clone --branch t44170_1 https://github.com/hackorum-dev/postgres.git

In a checkout you already have, add the fork once:

git remote add hackorum https://github.com/hackorum-dev/postgres.git

then, for this patchset and every later one:

git fetch hackorum t44170_1 && git checkout t44170_1

Patchset v1 (message #1) is on t44170_1

Jump to latest
#1Jeff Davis
pgsql@j-davis.com

The attached patch implements ALTER TABLE ... SET ACCESS METHOD.

For simplicity, I used the normal alter table path, ATRewriteTable(),
which does not follow the stricter isolation semantics that VACUUM FULL
follows. If someone thinks that's unacceptable, please let me know.

Regards,
Jeff Davis

Attachments:

t44170_1
alter-access-method.difftext/x-patch; charset=UTF-8; name=alter-access-method.diffDownload+95-9
#2Andres Freund
andres@anarazel.de
In reply to: Jeff Davis (#1)
Re: [v15] ALTER TABLE ... SET ACCESS METHOD

Hi,

On 2021-05-05 20:45:50 -0700, Jeff Davis wrote:

The attached patch implements ALTER TABLE ... SET ACCESS METHOD.

I think it'd be good to have a basic test for this. See create_am.sql
for how to do so without actually needing a second AM implementation.

For simplicity, I used the normal alter table path, ATRewriteTable(),
which does not follow the stricter isolation semantics that VACUUM FULL
follows. If someone thinks that's unacceptable, please let me know.

I think it'd be good to have something better for tablecmd.c table
rewrites - but I don't think it's this patch's responsibility.

Regards,

Andres

#3Justin Pryzby
pryzby@telsasoft.com
In reply to: Jeff Davis (#1)
Re: [v15] ALTER TABLE ... SET ACCESS METHOD

On Wed, May 05, 2021 at 08:45:50PM -0700, Jeff Davis wrote:

The attached patch implements ALTER TABLE ... SET ACCESS METHOD.

For simplicity, I used the normal alter table path, ATRewriteTable(),
which does not follow the stricter isolation semantics that VACUUM FULL
follows. If someone thinks that's unacceptable, please let me know.

Why doees your patch say v15?
It's nearly the same as my pre-existing patch, so should merge them.

https://commitfest.postgresql.org/33/3020/

--
Justin

#4Jeff Davis
pgsql@j-davis.com
In reply to: Justin Pryzby (#3)
Re: [v15] ALTER TABLE ... SET ACCESS METHOD

On Wed, 2021-05-05 at 23:40 -0500, Justin Pryzby wrote:

Why doees your patch say v15?
It's nearly the same as my pre-existing patch, so should merge them.

Sorry, I completely missed your patch. I retract mine and we'll
continue with yours.

Regards,
Jeff Davis