From: | Tim Landscheidt <tim(at)tim-landscheidt(dot)de> |
---|---|
To: | pgsql-sql(at)postgresql(dot)org |
Subject: | Re: Tweak sql result set... ? |
Date: | 2009-07-30 14:19:08 |
Message-ID: | m34osu2qzn.fsf@passepartout.tim-landscheidt.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
(anonymous) wrote:
>> > Any ideas on how to achieve this? I would like to let the original sql
>> > code stay original. I can prepare postgres before executing the sql if
>> > this makes it easier to acheive the goal
>> Have a look at CREATE RULE.
> Ok, you mean I could create a rule for the table, then I let the
> script go into my "black box",
> do the original selects, but get a manipulated result set back, then I
> drop the rule so
> that the blackbox of scripts can get the not manipulated result set
> back?
No, I meant that you should have a look at CREATE RULE. From
a design perspective, I'd probably rename the old table and
put an updatable view in its place.
> I need to sometimes get the result "<div>output from query</div>" and
> sometimes not
> and it would be awesomw to get it with the same query, but maybe by
> setting
> a rule or similar. Best from performance view would be to make
> something
> more permanent. Is it possible to activate/deactivate a rule?
Of course, DROP RULE.
Tim
From | Date | Subject | |
---|---|---|---|
Next Message | Rob Sargent | 2009-07-30 15:16:35 | Re: SQL report |
Previous Message | Axe | 2009-07-30 13:31:24 | Re: Tweak sql result set... ? |