Re: [GENERAL] Reg: BULK COLLECT

2015-05-27 Thread Andy Colson
On 05/25/2015 07:24 AM, Medhavi Mahansaria wrote: Hello, I am porting my application from Oracle to PostgreSQL. We are using BULK COLLECT functionality of oracle. How can i change the 'BULK COLLECT' fetch of the data from the cursor to make if compatible for pg/plsql? A small

Re: [GENERAL] Reg: BULK COLLECT

2015-05-27 Thread Simon Riggs
On 27 May 2015 at 06:52, Medhavi Mahansaria medhavi.mahansa...@tcs.com wrote: We are using bulk collect to enhance the performance as the data is huge. Using BULK COLLECT speeds up retrieving rows into memory, but if the data is huge that wasn't a great plan anyway, so doing it faster

Re: [GENERAL] Reg: BULK COLLECT

2015-05-26 Thread Medhavi Mahansaria
Mahansaria medhavi.mahansa...@tcs.com, pgsql-general@postgresql.org Date: 05/25/2015 06:15 PM Subject:Re: [GENERAL] Reg: BULK COLLECT On 05/25/2015 07:24 AM, Medhavi Mahansaria wrote: Hello, I am porting my application from Oracle to PostgreSQL. We are using BULK COLLECT

[GENERAL] Reg: BULK COLLECT

2015-05-25 Thread Medhavi Mahansaria
Hello, I am porting my application from Oracle to PostgreSQL. We are using BULK COLLECT functionality of oracle. How can i change the 'BULK COLLECT' fetch of the data from the cursor to make if compatible for pg/plsql? A small example is as below (This is just an example and the query is much

Re: [GENERAL] Reg: BULK COLLECT

2015-05-25 Thread Andy Colson
On 05/25/2015 07:24 AM, Medhavi Mahansaria wrote: Hello, I am porting my application from Oracle to PostgreSQL. We are using BULK COLLECT functionality of oracle. How can i change the 'BULK COLLECT' fetch of the data from the cursor to make if compatible for pg/plsql? A small example is as

Re: [GENERAL] Reg: BULK COLLECT

2015-05-25 Thread Allan Kamau
It seems you are fetching from a table then sequentially inserting each record to another table. In PostgreSQL, you could use cursors in PL/pgSQL ( http://www.postgresql.org/docs/9.4/interactive/plpgsql-cursors.html;). Alternatively you may write a single query which selects from the table and

Re: [GENERAL] Reg: BULK COLLECT

2015-05-25 Thread Adrian Klaver
On 05/25/2015 05:24 AM, Medhavi Mahansaria wrote: Hello, I am porting my application from Oracle to PostgreSQL. We are using BULK COLLECT functionality of oracle. How can i change the 'BULK COLLECT' fetch of the data from the cursor to make if compatible for pg/plsql? See here: