Re: How to insert huge string from file to text field via JDBC ?

Поиск
Список
Период
Сортировка
От liuyuanyuan
Тема Re: How to insert huge string from file to text field via JDBC ?
Дата
Msg-id 201308151710325164948@highgo.com.cn
обсуждение исходный текст
Ответ на How to insert huge string from file to text field via JDBC ?  (liuyuanyuan <liuyuanyuan@highgo.com.cn>)
Список pgsql-jdbc
        Thanks of all !
      Yes, this is unusual. But since a text field could store
up to 2GB , then I think  there must be a way to insert values up to 2G
in JDBC. I know about Large Object and bytea, and I just test text
datatype and want to get a exact result about whether we can insert
long string from huge file into text field or whst's the  maximum size.
     Hope to get more ideas from you.
 
 Best Regards! 
 Yours,
 Liu Yuanyuan
 
danap wrote:
>I have not tried with that size of document, but using a standard
>InputReader seems to work fine. Just setup a FileReader, buffer
>into a StringBuffer then when finished use the stringBuffer.toString()
>in the preparedStatement.
 
liuyuanyuan wrote:
> Hi,
>      Now I need to insert a huge string from a huge file (e.g. a 1 GB text document) to  a TEXT type field.
>      But I don't know any other way to insert string except setString() for preparedStatement.
>      Anyone know about this, please write to me. Thanks in advance!
 
 
 

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

Предыдущее
От: Pawel Veselov
Дата:
Сообщение: Re: PGConnectionPoolDataSource referencing problem
Следующее
От: Andreas Rudolph
Дата:
Сообщение: Re: BUG org.postgresql.Driver.connect() distorts InterruptedException