Discussion:
PostgreSQL 8.3.3 and pgSQL4RBv2r2
Sonny Taberman
2008-07-03 16:21:57 UTC
Permalink
Hi Marc.

It's been a long time since my last mail.
But now I run into truble again.:-)
I send a SQLcommand like this:
update workorder set status = 1 where workorder_id = 56042;
I expect this to land in the EmptyResult Event.
But I guess I'm wrong since that event will not trigger.

The result from this SQL command is:
UPDATE 1

Any ideas ?

regards

Sonny Taberman
LAN-Master AB
Aliacta Support
2008-07-03 20:07:46 UTC
Permalink
Hi Sonny,

The EmptyResult event only works for queries that do return a result,
like SELECT for instance. UPDATE does not return a result. If you
do a SELECT and no records match it, then the EmptyResult will be
triggered. It basically means zero records were found. UPDATE does
not return records and can therefore never have an EmptyResult.

Cheers,

Marc
Post by Sonny Taberman
Hi Marc.
It's been a long time since my last mail.
But now I run into truble again.:-)
update workorder set status = 1 where workorder_id = 56042;
I expect this to land in the EmptyResult Event.
But I guess I'm wrong since that event will not trigger.
UPDATE 1
Any ideas ?
regards
Sonny Taberman
LAN-Master AB
_______________________________________________
Postgresql mailing list
http://aliacta.com/mailman/listinfo/postgresql_aliacta.com
Loading...