Re: Table filter - Mailing list pgsql-general

From Joe Conway
Subject Re: Table filter
Date
Msg-id 47448586.6050107@joeconway.com
Whole thread Raw
In response to Table filter  (Reg Me Please <regmeplease@gmail.com>)
Responses Re: Table filter  (Reg Me Please <regmeplease@gmail.com>)
List pgsql-general
Reg Me Please wrote:

> The meaning is that an entity called by the value of "item" has a number
> of properties called by "property" with value "prop_value".
> So, for a single "item" there can be many different "property" each with its
> own value.

> A filter is a list of property values needed to qualify an entity as
> "good". An entity evaluates as good only when all property values in the
> filter match the ones associated to an item in t_data.
>
> What's missing to me is how to apply a filter to the t_data and get the list
> of the items that evaluate good.

I haven't played with it myself, but it seems to me that you could do
this with an inner join of two crosstabs -- one on t_data and one on the
filters (i.e. you join on the columns of the filter crosstab to the
matching ones in the t_data crosstab).

Joe



pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: loading a funtion script from a file
Next
From: "Scott Marlowe"
Date:
Subject: Re: loading a funtion script from a file