<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:10pt"><div><span>Thanks guys.</span></div><div><span></span> </div><div><span>But first of all I have to do this with pl/pgsql. This is not the matter of having answer in my db. It is the matter of solving problem with pl/pgsql.</span></div><div><span></span> </div><div><span>Rémi-C thank you for the link. I already went through it but it just explain very basic structure. I couldn't find my answers there.</span></div><div><span></span> </div><div><span>Bobb, I don't have any hk_id in my polygons table. I am going to find it and sign their h_id in the table.</span></div><div><span></span> </div><div><span>Do you know how to write this part in pl format? then I think I would understand how to go through the rest of my
 code.</span></div><div><span></span> </div><div><span>Cheers</span></div></div></body></html>