Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Two questions in Oracle...

Re: Two questions in Oracle...

From: Sybrand Bakker <postmaster_at_sybrandb.demon.nl>
Date: Thu, 26 Aug 1999 20:49:45 +0200
Message-ID: <935693418.14879.0.pluto.d4ee154e@news.demon.nl>


Ok, It seems this is NOT a quiz, so Thomas Kyte IS allowed to enter :)

The _ is the single character wildcard. You need to use LIKE 'L\_%' ESCAPE '\' to get the desired behavior. This is a good question for OCP.

2)
Your syntax seems to be correct. Since you don't post the exact error message, it is impossible to help you out.

Hth,

Sybrand Bakker, Oracle DBA

Jimmy <c6635500_at_comp.polyu.edu.hk> wrote in message news:37C60A34.BA2A611B_at_comp.polyu.edu.hk...
> Hello all,
> I have two questions: (in Oracle 7.3.3)
>
> 1) Why the following SQL statement returns 'aaa'?
>
> select 'aaa' from dual where 'LOW_D_LIMIT' like 'L_%';
>
> Is '_' means special character? 'LOW_D_LIMIT' not contains the
> string like 'L_' and it should return 'no rows returned' I
> think......... but it returns 'aaa'....
>
> 2) I want to develop a trigger like this:
>
> create or replace trigger testing
> after update or insert or delete on aaa
> begin
> if updating then
> if updating(fieldA) then
> pro1;
> end if;
> pro_all;
> elsif inserting then
> ...
> elsif deleting then
> ...
> end if;
> end;
> /
>
> If update column fieldA, then do pro1 and pro_all Other columns
> updating do only pro_all.
> However, errors in creating this trigger.... Is it possible to check
> which column is updated in the updating part? I cannot do this:
>
> create or replace trigger testing
> after update(fieldA) or insert or delete on aaa
> ...
>
> since this trigger only fired if fieldA is updated.
>
> Thanks,
> Jimmy
>
>
Received on Thu Aug 26 1999 - 13:49:45 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US