pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Gene Selkov Jr. <selkovjr@mcs.anl.gov>
To: Frank Barknecht <barknech@ph-cip.uni-koeln.de>
To: pgsql-sql@hub.org
Subject: Re: [SQL] Text type
Date: Fri, 15 Jan 1999 14:39:16 -0500
Message-ID: <199901152037.OAA04982@mail.xnet.com> (raw)
In-Reply-To: <19990114162848.A1573@fliwatut>

> I consider changing to a large object type field instead but how can I
> conveniently insert, change and search the text there? 

Large objects are nothing but files with a postgres OID. You will save
yourself a lot of hassle by treating your text as files.

You inset a text by creating a file and inserting its name in a table.

You change it by editing or replacing the file.

In order to search your texts, split them up and load into a table one
word per row. This will also allow you to build an index. Numbering
those words in a sequential order will also allow sequences, or
phrases, to be matched. If you need a full text search, refer to
contrib/fulltextindex or search files directly with grep. The latter
will work if the number of files in one directory does not exceed the
maximum number of command line arguments your system supports (which
is about 2000 in most linuxes, but can be ridiculously small in other
systems (e. g., 80 on IRIX).

--Gene



view thread (6+ messages)

Message-ID: <199901152037.OAA04982@mail.xnet.com>
Permalink:  ../199901152037.OAA04982@mail.xnet.com/
Also on:    postgresql.org/message-id/199901152037.OAA04982@mail.xnet.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: selkovjr@mcs.anl.gov, barknech@ph-cip.uni-koeln.de, pgsql-sql@hub.org
  Subject: Re: [SQL] Text type
  In-Reply-To: <199901152037.OAA04982@mail.xnet.com>
  References: <19990114162848.A1573@fliwatut> <199901152037.OAA04982@mail.xnet.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox