Re: An Idea for planner hints - Mailing list pgsql-hackers

From Greg Stark
Subject Re: An Idea for planner hints
Date
Msg-id 8764gry7kd.fsf@stark.xeocode.com
Whole thread Raw
In response to Re: An Idea for planner hints  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
Peter Eisentraut <peter_e@gmx.net> writes:

> Gregory Stark wrote:
> > I'm not sure it's worth throwing out the more user-friendly interface
> > we have now but I think it's clear that a table is the obvious
> > "machine-readable format" if you're already sitting in an SQL
> > database... :)
> 
> Then again, a table might not be the optimal format for an inherently 
> hierarchical structure.

If it were up to me I would just promote ltree to a standard data type and use
that.

On an only tangentially note it seems like the bootstrap sequence could be
split into two steps. The table definitions and the data types, operators, and
operator classes necessary for those table definitions have to be done in some
kind of C bootstrap code as it is now. However much of the bootstrap code now
could be split off into a standard SQL script.

That would save us a ton of headaches in getting OIDs to line up across tables
and make it easier to add new data types with all their associated operators
and operator classes. Worse, new access methods require defining new operator
classes for all the data types you want to support.

It's much easier to just copy paste the CREATE statements and let the SQL
engine assign all the ids and match up all the records.

-- 
greg



pgsql-hackers by date:

Previous
From: Greg Stark
Date:
Subject: Re: Enum proposal / design
Next
From: Martijn van Oosterhout
Date:
Subject: Re: pgstattuple extension for indexes