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

Home -> Community -> Usenet -> c.d.o.server -> Re: Creating Error Log table

Re: Creating Error Log table

From: Andreas Sheriff <spamcontrol_at_iion.com>
Date: Sat, 20 May 2006 11:43:27 -0700
Message-ID: <orJbg.6951$KB.1878@fed1read08>


<jthlcf_at_gmail.com> wrote in message
news:1148098569.277760.37340_at_38g2000cwa.googlegroups.com...
> Hi guys I am new to PL/SQL and trying to create an error event table
> that logs errors, naturally. I was wondering if you can help a newb to
> , yes LOL create TABLE like this. The difficulty that i have is in the
> following code that i use in ISQL
>
> CREATE TABLE EVENT_ERROR(
> row_id ROWID,
> table_name VARCHAR2(20),
> filter_id NUMBER,
> date_time DATE,
> action NUMBER(1) CHECK (action IN (2,3,4))
>
> I get the following error:
>
> action NUMBER(1) CHECK (action IN (2,3,4))
> *
>
> ERROR at line 6:
> ORA-00907: missing right parenthesis
>
>
> Anyone able to point me to wats wrong? Thanks heaps
>

Try this:

CREATE TABLE EVENT_ERROR(
row_id ROWID,
table_name VARCHAR2(20),
filter_id NUMBER,
date_time DATE,
action NUMBER(1) CHECK (action IN (2,3,4)))

Note the three parenthesess at the end.

-- 

Andreas Sheriff
Oracle 9i Certified Professional
Oracle 10g Certified Professional
Oracle 9i Certified PL/SQL Developer
----
"If you don't eat your meat, you cannot have any pudding.
"How can you have any pudding, if you don't eat your meat?"

DO NOT REPLY TO THIS EMAIL
Reply only to the group.
Received on Sat May 20 2006 - 13:43:27 CDT

Original text of this message

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