Re: [GENERAL] UPDATE cell from text file

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: [GENERAL] UPDATE cell from text file
Дата
Msg-id Pine.LNX.4.10.9910240414190.1284-100000@peter-e.yi.org
обсуждение исходный текст
Ответ на UPDATE cell from text file  ("Jason C. Wells" <jcwells@u.washington.edu>)
Ответы Re: [GENERAL] UPDATE cell from text file  ("Jason C. Wells" <jcwells@u.washington.edu>)
Список pgsql-general
On Oct 24, Jason C. Wells mentioned:

> This has got to be easy but I am having a hard time finding the right
> docs.
>
> What I want to do is analogous to:
>
> UPDATE website SET content='contents of a big ass file that I dont want to
> type on the command line' where filename='index.html';
>
> How can I do this?

In the psql interface this is not easily possible (read: impossible) short
of some sort of copy&paste as of this date. A mechanism which should get
this done (I hope) will appear in the new version, which, coincidentally,
will appear sometime next week, if you want to give it a shot.

Another issue to consider is whether all your data will fit into a row,
which will be false if "big ass" > BLCKSZ (8192 unless you changed it). In
that case you will have to use the large object interface for which there
is no mechanism in psql yet, but -- you guessed it -- there will be one
next week :)

    -Peter

--
Peter Eisentraut                  Sernanders vaeg 10:115
peter_e@gmx.net                   75262 Uppsala
http://yi.org/peter-e/            Sweden


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: [INTERFACES] Re: Errors in Postgres
Следующее
От: "Jason C. Wells"
Дата:
Сообщение: Re: [GENERAL] UPDATE cell from text file