Search Postgresql Archives

Re: Domains vs data types

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




> On 20 Aug 2025, at 7:47 AM, Ertan Küçükoglu <ertan.kucukoglu@xxxxxxxxx> wrote:
> 
> Hello,
> 
> I am using PostgreSQL 17.6.
> I would like to learn if there is any benefit of using domains over data types for table column definitions in terms of performance gain/loss.
> 


I know that this doesn’t answer your question, but before exploring custom types / domains,
and based on experience, I’d strongly recommend exploring jsonb instead as an alternative.

Also note that using custom types can lead to some confusion initially for basic stuff 
you can’t do things like SELECT mytype.f1 and instead you have to do (mytype).f1 
Things like this can get annoying pretty quickly.










[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux