Article View: pl.comp.bazy-danych
Article #194341Re: Oracle zapytanie do tabeli wewnątrz triggera (mutating)
From: Stokrotka
Date: Sun, 01 Mar 2015 17:55
Date: Sun, 01 Mar 2015 17:55
22 lines
1500 bytes
1500 bytes
>Chciałbym w triggerze before delete sprawdzać czy kasowany rekord jest >ostatnim. >czyli coś takiego: >select max(id) >into last_id >from table; >if (last_id is not null and last_id <> :old.id) then > raise_exception(...) >end if; A po co ci to? Jak cofasz transakcję , to zwykle inaczej się to realizuje, ale na oraclu się nie znam. -- (tekst bez: ó, ch, rz i -ii) Ortografia to NAWYK, często nielogiczny, ktury ludzie ociężali umysłowo, nażucają bezmyślnie następnym pokoleniom. http://ortografia.3-2-1.pl/
Technical Details
Message-ID:
<mcvjqd$pjc$1@usenet.news.interia.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.interia.pl!not-for-mailReferences:
<b4ff2e8e-8cce-4f92-bbc5-cab40f982e64@googlegroups.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!news.interia.pl!not-for-mail From: "Stokrotka" <ortografia.nowa@gazeta.pl> Newsgroups: pl.comp.bazy-danych Subject: Re: Oracle zapytanie do tabeli wewnątrz triggera (mutating) Date: Sun, 1 Mar 2015 18:55:15 +0100 Organization: INTERIA.PL S.A. Lines: 23 Message-ID: <mcvjqd$pjc$1@usenet.news.interia.pl> References: <b4ff2e8e-8cce-4f92-bbc5-cab40f982e64@googlegroups.com> NNTP-Posting-Host: ip-37-209-144-150.free.aero2.net.pl Mime-Version: 1.0 X-Trace: usenet.news.interia.pl 1425232525 26220 37.209.144.150 (1 Mar 2015 17:55:25 GMT) X-Complaints-To: usenet@firma.interia.pl NNTP-Posting-Date: Sun, 1 Mar 2015 17:55:25 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.3138 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit