Re: Implementing a join algorithm in Postgres

From: Ravi Kiran <ravi(dot)kolanpaka(at)gmail(dot)com>
To: Marcos Almeida Azevedo <marcos(dot)al(dot)azevedo(at)gmail(dot)com>
Cc: "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Implementing a join algorithm in Postgres
Date: 2015-03-30 08:03:57
Message-ID: CAOh57xE1KTjKkpOaEpVnvzKShDdL4JJucVEsoztW+0fkrQjCEg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,

I am actually implementing a Power of two choices Algorithm(A join
Algorithm used to join three tables based upon the Triangular query).

So for that I have written a C program which takes input from 3 files(1
file for each table) and will join the three tables. The algorithm is
working fine outside(I mean outside postgres).

Now I want the same algorithm(The C program which I have written) to behave
as a function in Postgres, I want this algorithm to be called when three
particular tables have been joined in the database. I want to know where
should I include this algorithm, whether in optimizer or executor, and if
possible could you be specific, like in which particular program of
optimizer or executor. and finally I want to find the time taken by this
algorithm and compare it with Nested loop algorithm.

Thank you.

On Mon, Mar 30, 2015 at 1:05 PM, Marcos Almeida Azevedo <
marcos(dot)al(dot)azevedo(at)gmail(dot)com> wrote:

>
>
> On Fri, Mar 27, 2015 at 5:44 PM, Ravi Kiran <ravi(dot)kolanpaka(at)gmail(dot)com>
> wrote:
>
>> Hi,
>>
>> I have written a C program which reads from 3 files(Each file is table
>> having 2 columns and thousands of rows).The program is used to join those 3
>> tables and the algorithm which I have written will work only for those 3
>> files. Now I want to test this program for postgres. Can someone tell me
>> how to do that, where should I include this program so that I can
>> successfully implement that program in postgres.
>>
>>
> Would you kindly elaborate what you wish to do
>
>
>> PS :- I already posted this query in pgsql-hackers, since I did not get
>> reply there, I am posting this query here.
>>
>> Thank you.
>>
>> --
>> Regards,
>>
>> K.Ravikiran
>>
>>
>> ᐧ
>>
>
>
>
> --
> Marcos | I love PHP, Linux, and Java
> <http://javadevnotes.com/java-integer-to-string-with-leading-zeros>
>

--
Regards,

K.Ravikiran
BITS Pilani Hyderabad Campus

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message avpro avpro 2015-03-30 08:20:15 Link Office Word form document with data from PostgreSQL
Previous Message Marcos Almeida Azevedo 2015-03-30 07:35:57 Re: Implementing a join algorithm in Postgres