tracking errors in psql

Поиск
Список
Период
Сортировка
От brian
Тема tracking errors in psql
Дата
Msg-id 455E04B7.5040800@zijn-digital.com
обсуждение исходный текст
Ответы Re: tracking errors in psql
Список pgsql-general
I've just gotten a dump from pgMyAdmin for a production database that i
wanted to update the dev db with. However, i'm seeing a multitude of
errors. From what i can see, the columns are mixed up in the COPY block
for a particular table. My guess is that a tab character has thrown
everything into disaray. The dump is structure & data, using COPY FROM
STDIN.

I have two questions:

1) What is the best way to track these errors? They pile up on each
other, so i can't just scroll back in the terminal (I could set the
buffer higher but i'd be scrolling all day).

2) Does anyone have any suggestions for removing the tabs in this
table's column? There's no good reason for them there (it's all HTML) so
i don't mind just removing them altogether. Do i need to use
regexp_replace(), or would replace() do the job? And are there any
quoting specifics required in order that the tab character is recognised?

Is this fine as is?

UPDATE member SET bio = replace(bio, '\t', '');

brian

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

Предыдущее
От: "Magnus Hagander"
Дата:
Сообщение: Re: Why the data changes it's value by itself!
Следующее
От: "Leodinei Bielak"
Дата:
Сообщение: Select slow over network