Parser - Query Analyser

From: Michael Giannakopoulos <miccagiann(at)gmail(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Parser - Query Analyser
Date: 2012-11-17 14:18:27
Message-ID: CAAADf7+eEi-XS+mdCR42y9GVdPB6QiBnObYq-e6tpsfF_du+GQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

Hello guys,

My name is Michail Giannakopoulos and I am a graduate student at University
of Toronto. I have no previous experience in developing a system like
postgreSQL before.

What I am trying to explore is if it is possible to extend postgreSQL in
order to accept queries of the form:

Select function(att1, att2, att3) AS output(out1, out2, ..., outk) FROM
[database_name];

where att1, att2, att3 are attributes of the relation [database_name] while
output(out1, out2, out3) expresses the output that comes from 'function'
and the fields that this output should have are (out1, out2, out3). What I
mean is that this kind of query should return tuples that obay to the
'output(...)' schema and are produced by processing the original tuples of
'database_name' relation in attributes att1, att2 and att3.

From what I have seen I need to teak both the parser and the query analyser
in order to accept this form of query. However, I do not know how to tweak
these systems. Even worse I do not know where to begin from.

The manual of extending SQL did not helped me and currently I am debugging
postgreSQL source code. I would appreciate if you could provide me with
more resources and correct ways of how to hack inside postgreSQL files and
system. For example, where do I add a new parse node, where should I change
the the grammar.

Thank you very much for all your time and all your help,
Michail

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David Johnston 2012-11-17 14:44:06 Re: Parser - Query Analyser
Previous Message T. E. Lawrence 2012-11-17 14:08:32 9.2 streaming replication issue and solution strategy

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2012-11-17 14:20:20 Re: foreign key locks
Previous Message Markus Wanner 2012-11-17 14:00:10 Re: logical changeset generation v3 - comparison to Postgres-R change set format