Return-Path: owner-postman
Received: from localhost (localhost [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with SMTP id BAA18354 for postgres-redist; Wed, 22 Jun 1994 01:41:18 -0700
Resent-From: POSTGRES mailing list <postman@postgres.Berkeley.EDU>
Resent-Message-Id: <199406220841.BAA18354@nobozo.CS.Berkeley.EDU>
X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost didn't use HELO protocol
Sender: owner-postman@postgres.Berkeley.EDU
X-Return-Path: owner-postman
Received: from hearnvax.nic.surfnet.nl (hearnvax.nic.surfnet.nl [192.87.5.131]) by nobozo.CS.Berkeley.EDU (8.6.4/8.6.3) with ESMTP id BAA18344 for <postgres@postgres.berkeley.edu>; Wed, 22 Jun 1994 01:41:12 -0700
Received: from frontier.tno.nl by HEARNVAX.nic.SURFnet.nl (PMDF V4.2-12 #3330)
 id <01HDU8WTWQV4007GVY@HEARNVAX.nic.SURFnet.nl>; Wed,
 22 Jun 1994 10:41:20 +0200 (MET-DST)
Received: from tpdusv.tpd.tno.nl by frontier.tno.nl (4.1/1.53) id AA22168; Wed,
 22 Jun 94 10:36:23 +0200
Received: by tpdusv.tpd.tno.nl (5.65/DEC-Ultrix/4.3/GVA) id AA28216; Wed,
 22 Jun 1994 10:40:58 +0200
Received: by tpdbbs.local (5.57/Ultrix3.0-C) id AA11118; Wed,
 22 Jun 94 10:40:57 +0200
Date: Wed, 22 Jun 1994 10:40:56 +0200 (MET DST)
From: ejonge@tpd.TNO.NL (Eric de Jonge)
Subject: TRANSACTION ?!
To: postgres@postgres.Berkeley.EDU (post list)
Cc: ejonge@tpd.TNO.NL (Eric de Jonge)
Message-id: <9406220840.AA11118@tpdbbs.local>
X-Envelope-to: postgres@postgres.berkeley.edu
X-Mailer: ELM [version 2.4 PL21]
Content-type: text
Content-transfer-encoding: 7BIT
Content-Length: 2186
Resent-To: postgres-redist@postgres.Berkeley.EDU
Resent-Date: Wed, 22 Jun 94 01:41:18 -0700
Resent-XMts: smtp

Hi,


I've a problem:

I want to add an attribute and define a rule whithin a TRANSACTION
(execute everything or nothing)

FOR EXAMPLE:

ejonge@tpdbbs> monitor testdb
Welcome to the POSTGRES terminal monitor

Go
* \i test

Query sent to backend is "retrieve (tabel.all)"
---------------
| fieldA      |
---------------



====> BEGIN TRANSACTION <======

Query sent to backend is "begin"
BEGIN
Query sent to backend is "addattr (fieldX=IMAGEOBJ) to tabel"
ADD
Query sent to backend is "retrieve (tabel.all)"
-----------------------------
| fieldA      | fieldX      |
-----------------------------

Query sent to backend is "define rule imd_tabefieldX is on delete to tabel 
do delete db_image where current.fieldX = db_image.path "
DEFINE
Query sent to backend is "end"
END

====> END TRANSACTION <======




Query sent to backend is "retrieve (tabel.all)"
-----------------------------
| fieldA      | fieldX      |
-----------------------------

(EVERYTHING'S OK; BUT NOW AGAIN)


====> BEGIN TRANSACTION <======

Query sent to backend is "begin"
BEGIN
Query sent to backend is "addattr (fieldY=IMAGEOBJ) to tabel"
ADD
Query sent to backend is "retrieve (tabel.all)"
-----------------------------
| fieldA      | fieldX      | <==== NO fieldY :-< ==
-----------------------------

Query sent to backend is "define rule imd_tabefieldY is on delete to tabel 
do delete db_image where current.fieldY = db_image.path "
WARN:Jun 20 12:26:07:Invalid attribute fieldY



=================================================
====> PROBLEM:

FIELDY ISN'T ADD (SO CAN'T DEFINE A RULE)


(Paul Oaki: sometimes buffers for dead databases just don't flush out of
the buffer cache.  haven't got a clue as to what causes it. :-( )

Thanks in advance,
-- 
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
_/ Eric de Jonge               _/ Phone: +31 15-692225                  _/
_/ TNO-TPD SV                 _/ Fax: +31 15-692111                     _/
_/                           _/ P.O.Box 155                            _/
_/ Email: ejonge@tpd.tno.nl _/ 2600 AD Delft, The Netherlands         _/
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_//_/_/_/_/_/_/

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU"

   If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================
