Re: [HACKERS] Mentors needed urgently for SoC & PostgreSQL Student Internships

From: Jeff Davis <pgsql(at)j-davis(dot)com>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: Josh Berkus <josh(at)agliodbs(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, lembark(at)wrkhors(dot)com, pgsql-hackers(at)postgresql(dot)org, pgsql-www(at)postgresql(dot)org
Subject: Re: [HACKERS] Mentors needed urgently for SoC & PostgreSQL Student Internships
Date: 2009-04-02 19:40:16
Message-ID: 1238701216.29661.24.camel@dell.linuxdev.us.dell.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-www

On Thu, 2009-04-02 at 21:58 +0300, Heikki Linnakangas wrote:
> > I have not yet implemented temporal join.
>
> That, and temporal union and difference. You have a union operator, but
> that's not enough for a temporal union, as in:

Ok, so you were talking about the relational operators, not interval
predicates or interval operators. I agree that the relational operators
are non-trivial.

> Also, it would be nice to generalize the thing so that it works not only
> with intervals of time, but also floats, integers, numerics etc. The
> concept of an interval is not really tied to timestamps, even though
> that's probably the most common use case in the business world.

Yeah. I thought about how to do that with typmod, but it doesn't allow
storing an entire OID for the constituent types. It may be possible to
work around that.

> > A big open question is whether we do new syntax, and if so, what. A lot
> > of the literature for temporal types out there (from people basing their
> > suggestions on SQL, like Snodgrass, et al., not C.J. Date) suggests
> > syntax extensions which seem pretty specialized and unnecessary to me,
> > but perhaps convenient.
>
> I can't imagine how you would implement temporal joins and unions
> without syntax extensions. If there is a way, that would be great,
> because that might allow us to implement them without backend changes.

I still didn't know you were talking about relational operators at that
point. Temporal join, union, difference, and also probably table logs
all require syntax (not "require" maybe, but it would help a lot).

The unnecessary syntax I was referring to is the SQL-ish syntax
suggested by Snodgrass, et al, which involves words for things like
"overlaps", which we really don't need.

> > The only thing I really think needs better syntax is a constructor that
> > can easily represent [ ), [ ], ( ), ( ] -- i.e. inclusive/exclusive.
> > Right now I have 4 functions to do that, but it's awkward and overly
> > verbose.
>
> Can't the input function handle those? Or you could have just one
> constructor with an extra argument indicating whether each end of the
> range is exclusive or inclusive.

Constructing from a single string is easy. What happens when you want to
say ( 2009-01-01, now() ], or pass a timestamptz from a table? Ideas
welcome.

Regards,
Jeff Davis

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2009-04-02 19:48:38 Re: More message encoding woes
Previous Message Peter Eisentraut 2009-04-02 19:26:34 Re: Path case sensitivity on windows

Browse pgsql-www by date

  From Date Subject
Next Message Robert Haas 2009-04-02 20:07:04 Re: [HACKERS] Mentors needed urgently for SoC & PostgreSQL Student Internships
Previous Message Heikki Linnakangas 2009-04-02 18:58:02 Re: [HACKERS] Mentors needed urgently for SoC & PostgreSQL Student Internships