I am new to this forum and PostgreSQL so excuse me if my question may be simple. I am developing a custom solution for a customer that reads a list of items from a PostgreSQL version 7.3 on a linux box. Now I program in C#.NET and would need an equivalent solution to MS Server SP solution for Custom paging in a DataGrid. The MS solution can be found at this link


What is needed is a SP or Function in PostgreSQL that reads a pre determined set of records from a Temporary Table filled by a Select Statement. I tried a couple of things but with normal SQL language I was not able to achieve normal transactional operations (Declare local variable, etc.) Can anybody help me with this one?
I think pl/Sql is needed here and I do not know this language.
Thanks for your help!