pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
How to REMOVE a fillfactor set by accident?
5+ messages / 4 participants
[nested] [flat]

* How to REMOVE a fillfactor set by accident?
@ 2020-12-31 20:13 Thorsten Schöning <tschoening@am-soft.de>
  2020-12-31 20:24 ` Re: How to REMOVE a fillfactor set by accident? Ron <ronljohnsonjr@gmail.com>
  2020-12-31 20:31 ` Re: How to REMOVE a fillfactor set by accident? Thomas Kellerer <shammat@gmx.net>
  0 siblings, 2 replies; 5+ messages in thread

From: Thorsten Schöning @ 2020-12-31 20:13 UTC (permalink / raw)
  To: PostgreSQL General <pgsql-general@lists.postgresql.org>

Hi all,

I'm using the GUI tool pgModeler to maintain schemas and at some point
in the past it used fillfactor 10 for some indexes by default. That
seems to have changed in the meantime and most of my indexes don't
have ANY fillfactor set explicitly.

Is there some way to REMOVE the fillfactor where it is set, so that
Postgres applies it's defaults? Would be great to have an output of
NULL everywhere where fillfactor is output instead of sometimes e.g.
100 and more often NULL.

I've already tried setting things to NULL, which failed with
mentioning that a decimal number is necessary. Though, even setting 0
fails, because a value between 10 and 100 is required.

> ALTER INDEX  pk_clt_rec_src SET (fillfactor = NULL);
> ALTER INDEX  pk_clt_rec_src SET (fillfactor = 0);

So removing isn't possible at all and I can only set to concrete
values like 100 or don't care at all instead? Because fillfactor=10 is
only set for some low throughput test databases currently.

Thanks!

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning
AM-SoFT IT-Service - Bitstore Hameln GmbH

E-Mail:  Thorsten.Schoening@AM-SoFT.de
Web:     http://www.AM-SoFT.de/

Telefon: 05151-  9468-55
Fax:     05151-  9468-88
Mobil:    0178-8 9468-04

Firmensitz: Bitstore IT-Consulting, Frankfurter Allee 285, 10317 Berlin
Steuernummer 037/230/30566, HR 27198, Amtsgericht Potsdam Geschäftsführer Janine Galonska






^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: How to REMOVE a fillfactor set by accident?
  2020-12-31 20:13 How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
@ 2020-12-31 20:24 ` Ron <ronljohnsonjr@gmail.com>
  2020-12-31 20:33   ` Re: How to REMOVE a fillfactor set by accident? David G. Johnston <david.g.johnston@gmail.com>
  1 sibling, 1 reply; 5+ messages in thread

From: Ron @ 2020-12-31 20:24 UTC (permalink / raw)
  To: pgsql-general@lists.postgresql.org

On 12/31/20 2:13 PM, Thorsten Schöning wrote:
> Hi all,
>
> I'm using the GUI tool pgModeler to maintain schemas and at some point
> in the past it used fillfactor 10 for some indexes by default. That
> seems to have changed in the meantime and most of my indexes don't
> have ANY fillfactor set explicitly.
>
> Is there some way to REMOVE the fillfactor where it is set, so that
> Postgres applies it's defaults? Would be great to have an output of
> NULL everywhere where fillfactor is output instead of sometimes e.g.
> 100 and more often NULL.
>
> I've already tried setting things to NULL, which failed with
> mentioning that a decimal number is necessary. Though, even setting 0
> fails, because a value between 10 and 100 is required.
>
>> ALTER INDEX  pk_clt_rec_src SET (fillfactor = NULL);
>> ALTER INDEX  pk_clt_rec_src SET (fillfactor = 0);
> So removing isn't possible at all and I can only set to concrete
> values like 100 or don't care at all instead? Because fillfactor=10 is
> only set for some low throughput test databases currently.

https://www.postgresql.org/docs/12/sql-createindex.html

There *must* be a fill factor; that's how B-tree, hash, GiST and SP-GiST 
indices work.

The default fill factor is 90%; thus, to "remove" your custom fill factor, 
set it to 90%.

-- 
Angular momentum makes the world go 'round.

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: How to REMOVE a fillfactor set by accident?
  2020-12-31 20:13 How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
  2020-12-31 20:24 ` Re: How to REMOVE a fillfactor set by accident? Ron <ronljohnsonjr@gmail.com>
@ 2020-12-31 20:33   ` David G. Johnston <david.g.johnston@gmail.com>
  0 siblings, 0 replies; 5+ messages in thread

From: David G. Johnston @ 2020-12-31 20:33 UTC (permalink / raw)
  To: Ron <ronljohnsonjr@gmail.com>; +Cc: pgsql-generallists.postgresql.org <pgsql-general@lists.postgresql.org>

On Thu, Dec 31, 2020 at 1:24 PM Ron <ronljohnsonjr@gmail.com> wrote:

> Is there some way to REMOVE the fillfactor where it is set, so that
> Postgres applies it's defaults? Would be great to have an output of
> NULL everywhere where fillfactor is output instead of sometimes e.g.
> 100 and more often NULL.
>
> I've already tried setting things to NULL, which failed with
> mentioning that a decimal number is necessary. Though, even setting 0
> fails, because a value between 10 and 100 is required.
>
>
> ALTER INDEX  pk_clt_rec_src SET (fillfactor = NULL);
> ALTER INDEX  pk_clt_rec_src SET (fillfactor = 0);
>
> So removing isn't possible at all and I can only set to concrete
> values like 100 or don't care at all instead? Because fillfactor=10 is
> only set for some low throughput test databases currently.
>
>
> https://www.postgresql.org/docs/12/sql-createindex.html
>
> There *must* be a fill factor; that's how B-tree, hash, GiST and SP-GiST
> indices work.
>
> The default fill factor is 90%; thus, to "remove" your custom fill factor,
> set it to 90%.
>
>
Since the index already exists the "ALTER INDEX" documentation is more
pertinent.  And behold:

ALTER INDEX [ IF EXISTS ] name RESET ( storage_parameter [, ... ] )

David J.

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: How to REMOVE a fillfactor set by accident?
  2020-12-31 20:13 How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
@ 2020-12-31 20:31 ` Thomas Kellerer <shammat@gmx.net>
  2021-01-01 13:34   ` Re: How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
  1 sibling, 1 reply; 5+ messages in thread

From: Thomas Kellerer @ 2020-12-31 20:31 UTC (permalink / raw)
  To: pgsql-general@lists.postgresql.org

Thorsten Schöning schrieb am 31.12.2020 um 21:13:
> Is there some way to REMOVE the fillfactor where it is set, so that
> Postgres applies it's defaults? Would be great to have an output of
> NULL everywhere where fillfactor is output instead of sometimes e.g.
> 100 and more often NULL.
>
> I've already tried setting things to NULL, which failed with
> mentioning that a decimal number is necessary. Though, even setting 0
> fails, because a value between 10 and 100 is required.
>
>> ALTER INDEX  pk_clt_rec_src SET (fillfactor = NULL);
>> ALTER INDEX  pk_clt_rec_src SET (fillfactor = 0);
>

ALTER INDEX pk_clt_rec_src RESET (fillfactor);

should do it.






^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: How to REMOVE a fillfactor set by accident?
  2020-12-31 20:13 How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
  2020-12-31 20:31 ` Re: How to REMOVE a fillfactor set by accident? Thomas Kellerer <shammat@gmx.net>
@ 2021-01-01 13:34   ` Thorsten Schöning <tschoening@am-soft.de>
  0 siblings, 0 replies; 5+ messages in thread

From: Thorsten Schöning @ 2021-01-01 13:34 UTC (permalink / raw)
  To: pgsql-general@lists.postgresql.org

Guten Tag Thomas Kellerer,
am Donnerstag, 31. Dezember 2020 um 21:31 schrieben Sie:

> ALTER INDEX pk_clt_rec_src RESET (fillfactor);

Thanks, should have looked into the docs instead of googling only! :-)

Mit freundlichen Grüßen,

Thorsten Schöning

-- 
Thorsten Schöning
AM-SoFT IT-Service - Bitstore Hameln GmbH

E-Mail:  Thorsten.Schoening@AM-SoFT.de
Web:     http://www.AM-SoFT.de/

Telefon: 05151-  9468-55
Fax:     05151-  9468-88
Mobil:    0178-8 9468-04

Firmensitz: Bitstore IT-Consulting, Frankfurter Allee 285, 10317 Berlin
Steuernummer 037/230/30566, HR 27198, Amtsgericht Potsdam Geschäftsführer Janine Galonska






^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2021-01-01 13:34 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-12-31 20:13 How to REMOVE a fillfactor set by accident? Thorsten Schöning <tschoening@am-soft.de>
2020-12-31 20:24 ` Ron <ronljohnsonjr@gmail.com>
2020-12-31 20:33   ` David G. Johnston <david.g.johnston@gmail.com>
2020-12-31 20:31 ` Thomas Kellerer <shammat@gmx.net>
2021-01-01 13:34   ` Thorsten Schöning <tschoening@am-soft.de>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox