Re: user constructed where clause

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: "Yelai, Ramkumar IN BLR STS" <ramkumar(dot)yelai(at)siemens(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: user constructed where clause
Date: 2015-06-09 20:17:55
Message-ID: CAKFQuwY1Ep2gDE3B2cWZkK4pDgMm-stG9f340m1HVoHB9sMifw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Jun 9, 2015 at 4:48 AM, Yelai, Ramkumar IN BLR STS <
ramkumar(dot)yelai(at)siemens(dot)com> wrote:

> Now, the requirement is if user provides filter information based on
> every column from the web UI, this filter will let the user construct the
> “where clause” and provide to postgresql.
> In a month this table exceeds millions of record. If I use the
> user-constructed query then it would take lot of time as the user may not
> include indexed column in the user-constructed query.
>

​The first solution that comes to mind is to construct a document
containing the relevant information, index that, and then provide a single
search input field that is used to construct a text search query that you
apply against the indexed document.

In short, forget the fact that there are fields and just index and search
the content.

Add additional controls to the UI for just those fields that are indexed.

David J.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2015-06-09 23:00:24 The purpose of the core team
Previous Message Ravi Tammineni 2015-06-09 18:07:24 Re: Postgresql BDR Replication Setup Issue