Oracle Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesOracle Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old May 16th, 2005, 02:03 PM
yongho yongho is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Posts: 57 yongho User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 6 h 38 m 20 sec
Reputation Power: 5
Ora-04089 =(

ORA-04089: cannot create triggers on objects owned by SYS


CREATE OR REPLACE TRIGGER ValidateNation
AFTER INSERT OR UPDATE OF Nation ON ALLOWED_NATIONALITY

FOR EACH ROW

DECLARE

rowCount integer;

BEGIN

/* Look for the new nation in the Allowed_nationality Table. */
SELECT Count(*)INTO rowcount
FROM ALLOWED_NATIONALITY PA
WHERE :new.Nation = PA.NATION

/* If the nation doest not exists in the table, then send warning message */
If rowCount < 1 then
DBMS_OUTPUT.PUT_LINE ('An artist with '|| :new.Nation ||' does not exist');

End if;

END;
/


I need a bit of guidance, and I'm a little confused as to what I'm supposed to do.

Reply With Quote
  #2  
Old May 17th, 2005, 04:01 AM
pabloj's Avatar
pabloj pabloj is offline
Modding: Oracle MsSQL Firebird
Dev Shed God 6th Plane (7500 - 7999 posts)
 
Join Date: Jun 2001
Location: Outside US
Posts: 7,917 pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level)pabloj User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Months 3 Weeks 3 Days 15 h 52 m 3 sec
Reputation Power: 279
ORA-04089: cannot create triggers on objects owned by SYS
Seems you have created your application tables in the SYS schema, which is an overprivileged user to be used only for database maintenance.
This is one of the worst things you can do.

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesOracle Development > Ora-04089 =(


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT