Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty()
От | Bruce Momjian |
---|---|
Тема | Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty() |
Дата | |
Msg-id | 20160730181643.GD22405@momjian.us обсуждение исходный текст |
Ответ на | Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty() (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty()
pg_size_pretty, SHOW, and spaces Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty() Re: [BUGS] BUG #14244: wrong suffix for pg_size_pretty() |
Список | pgsql-hackers |
On Sat, Jul 30, 2016 at 10:35:58AM -0400, Tom Lane wrote: > Greg Stark <stark@mit.edu> writes: > > I think Bruce's summary is a bit revisionist. > > I would say it's a tempest in a teapot. > > What I think we should do is accept "kb" and the rest case-insensitively, > print them all in all-upper-case always, and tell standards pedants > to get lost. The idea of introducing either a GUC or new function names > is just silly; it will cause far more confusion and user code breakage > than will result from just leaving well enough alone. I agree that a GUC and new functions are overkill --- we should just decide on the format we want to output and what to support for input. As logical as the IEC format appears, I just don't think the Ki/Mi/Gi prefixes are used widely enough for us to use it --- I think it will cause too many problem reports: https://en.wikipedia.org/wiki/Binary_prefix I have developed two possible patches for PG 10 --- the first one merely allows "KB" to be used in addition to the existing "kB", and documents this as an option. The second patch does what Tom suggests above by outputting only "KB", and it supports "kB" for backward compatibility. What it doesn't do is to allow arbitrary case, which I think would be a step backward. The second patch actually does match the JEDEC standard, except for allowing "kB". I also just applied a doc patch that increases case and spacing consistency in the use of kB/MB/GB/TB. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + As you are, so once was I. As I am, so you will be. + + Ancient Roman grave inscription +
Вложения
В списке pgsql-hackers по дате отправления: