Re: psql \copy hanging

Поиск
Список
Период
Сортировка
От Adrian Klaver
Тема Re: psql \copy hanging
Дата
Msg-id 5612153a-af11-38da-c34e-8b4bab9cfc8e@aklaver.com
обсуждение исходный текст
Ответ на Re: psql \copy hanging  ("Arnaud L." <arnaud.listes@codata.eu>)
Ответы Re: psql \copy hanging  ("Arnaud L." <arnaud.listes@codata.eu>)
Список pgsql-general
On 10/8/19 12:06 AM, Arnaud L. wrote:
> Le 07/10/2019 à 16:36, Adrian Klaver a écrit :
>> So you are saying that you have not run the problematic line by itself?
> 
> It hung during last night's run.
> 
> I had modified my batch script to run the \copy commands separately, 
> i.e. it now reads as :
> psql -h myserver -a mydb < originalscriptwithoutproblematicline.sql
> psql -h myserver -a mydb < problematicline.sql

This is going to be hard to troubleshoot if you change your commands.

Previously you had:
psql -h %MYPGSERVER% -a -f myscript.sql %MYPGDB%

Changing more then one thing at a time makes it that much more difficult 
to isolate the issue.

I would create an entirely separate batch file that runs just 
problematicline.sql.

Given that you suspect Postgres it would be helpful to see the query 
that underlies the view you are copying.

You might want to look at autoexplain:

https://www.postgresql.org/docs/11/auto-explain.html

as a way of getting information at run time.


> 
> It hung at the problematic line, so during the second psql command.
> 
> I'm really at loss... I *believe* that the problem lies either in psql 
> or in PostgreSQL, but I really don't know what to try now.
> 
> 
> Regards
> -- 
> Arnaud
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com



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

Предыдущее
От: Shatamjeev Dewan
Дата:
Сообщение: RE: Declarative Range Partitioning Postgres 11
Следующее
От: "Arnaud L."
Дата:
Сообщение: Re: psql \copy hanging