Re: Is there any limit on the number of rows to import using copy command

Поиск
Список
Период
Сортировка
От Adrian Klaver
Тема Re: Is there any limit on the number of rows to import using copy command
Дата
Msg-id cd5ad7f0-9506-4828-9c13-88f34e8e4c8c@aklaver.com
обсуждение исходный текст
Ответ на Re: Is there any limit on the number of rows to import using copy command  ("sivapostgres@yahoo.com" <sivapostgres@yahoo.com>)
Ответы Re: Is there any limit on the number of rows to import using copy command
Список pgsql-general
On 7/24/25 05:18, sivapostgres@yahoo.com wrote:
> Thanks Merlin, adrain, Laurenz
> 
> As a testcase, I split the trigger function into three, one each for 
> insert, update, delete, each called from a separate trigger.
> 
> IT WORKS!.

It worked before, it just slowed down as your cases got bigger. You need 
to provide more information on what test case you used and how you 
define worked.

> 
> Shouldn't we have one trigger function for all the three trigger 
> events?  Is it prohibited for bulk insert like this?

No. Triggers are overhead and they add to the processing that need to be 
done for moving the data into the table. Whether that is an issue is a 
case by case determination.

> 
> I tried this in PGAdmin only, will complete the testing from the program 
> which we are developing, after my return from holiday.

 From Merlin Moncure's post:

"* reconfiguring your logic to a procedure can be a better idea; COPY
your data into some staging tables (perhaps temp, and indexed), then
write to various tables with joins, upserts, etc."

I would suggest looking into implementing the above.

> 
> Happiness Always
> BKR Sivaprakash
> 



-- 
Adrian Klaver
adrian.klaver@aklaver.com



В списке pgsql-general по дате отправления: