Subject | Re: access rights error when updating on a view with triggers |
---|---|
Author | Doru Ilasi |
Post date | 2008-05-16T06:13:59Z |
The code example were bad. See the reposted one.
Thank you Sean,
Doru
Thank you Sean,
Doru
--- In firebird-support@yahoogroups.com, "Leyne, Sean" <Sean@...> wrote:
>
> Doru,
>
> > create trigger test_vw_bu for test_vw active before update
> > as begin
> > update test set f2 = new.f1;
> > end
>
> > -- login as USERNAME
> > update test_vw set f1 ='N';
> >
> > will raise : Stetement failed, SQLCODE = -551
> > No permission for update/write access to COLUMN F2
>
> I suspect that your install has the wrong Firebird.msg file. I believe
> the error is due to improper SQL syntax in your UPDATE statement. The
> correct syntax should be:
>
> create trigger test_vw_bu for test_vw active before update
> as begin
> update test set f2 = :new.f1;
> end
>
> (Note the ":" in front of "new.f1")
>
>
> Sean
>