Main Tables Views Materialized Views Indexes Constraints Triggers Procedures Functions Packages Sequences Java Sources Sanity Check Index DDL scrips
Description Columns Primary key Check Constraints Foreign keys Unique Keys Options Indexes Referenced by Triggers Partitions

RHNORGQUOTA

DDL script

Columns

NameTypeNullableDefault valueComment
ORG_IDNUMBER(38)N  
TOTALNUMBER(38)N(0)  
BONUSNUMBER(38)N(0)  
USEDNUMBER(38)N(0)  
CREATEDDATEN(sysdate)  
MODIFIEDDATEN(sysdate)  

Foreign Keys:

Constraint NameColumnsReferenced tableReferenced ConstraintOn Delete Rule
RHN_ORGQUOTA_OID_FKORG_ID WEB_CUSTOMER WEB_CUSTOMER_ID_PK NO ACTION

Options:

OptionSettings
TablespaceDATA_TBS
Index OrganizedNo
Generated by OracleNo
ClusteredNo
NestedNo
TemporaryNo

Indexes:

Index NameTypeUnuquenessColumnsDDL script
RHN_ORGQUOTA_OID_UQNORMALUNIQUEORG_ID DDL script

Triggers

RHN_ORGQUOTA_MOD_TRIG

Legend: comment string keyword reserved word operator
CREATE TRIGGER 
rhn_orgquota_mod_trig
before insert or update on rhnOrgQuota
for each row

REFERENCING NEW AS NEW OLD AS OLD
declare
	available_quota number;
begin
	:new.modified := sysdate;
	available_quota := :new.total + :new.bonus;
	if :new.used gt; available_quota then
		rhn_exception.raise_exception('not_enough_quota');
	end if;
end;