Re: PGAdmin cuts sql when show rules

Khushboo Vashi <[email protected]>
Newsgroups gmane.comp.db.postgresql.pgadmin
Message-ID <CAFOhELdwy6c5gpAKFBp-7fuxtpj4sq_EWFqEkDq22-uLKen6-Q@mail.gmail.com>
Hi,

On Wed, Aug 7, 2019 at 4:08 PM Мытарев Евгений <[email protected]> wrote:

> Hi,
>
> I have a bug in 4.11.  It show rules sql incorrect.
>
>
> Please log this issue @ https://redmine.postgresql.org/projects/pgadmin4 .

Thanks,
Khushboo

> My rule is
>
> CREATE OR REPLACE RULE replace_expression_answer AS
>     ON INSERT TO dict.expression_answer
>    WHERE (EXISTS ( SELECT 1
>            FROM dict.expression_answer expression_answer_1
>           WHERE expression_answer_1.id = new.id AND
> expression_answer_1.expression_id = new.expression_id)) DO INSTEAD  UPDATE
> dict.expression_answer SET header = new.header, condition = new.condition,
> formula = new.formula
>   WHERE expression_answer.id = new.id AND expression_answer.expression_id
> = new.expression_id;
>
>
>
> But in PGAdmin 4 I see only
>
> CREATE OR REPLACE RULE replace_expression_answer AS
>     ON INSERT TO dict.expression_answer
>     WHERE expression_answer_1.id = new.id AND
> expression_answer_1.expression_id = new.expression_id))
>     DO INSTEAD
> UPDATE dict.expression_answer SET header = new.header, condition =
> new.condition, formula = new.formula
>   WHERE expression_answer.id = new.id AND expression_answer.expression_id
> = new.expression_id;
>
>
>
>
>
>
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.