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 -> Design Question: Trigger? Stored Procedure?

Design Question: Trigger? Stored Procedure?

From: Ken Rachynski <krachyn_at_evansconsoles.com>
Date: 8 Feb 2000 10:43:21 -0700
Message-ID: <8ED4632C6krachynec@204.50.1.43>


Good day,

I have a table as follows:

CREATE TABLE PRODUCTMIX (

  PROJECT_LEAD_ID  NUMBER( 38 )  NOT NULL, 
  PRODUCT_TYPE     VARCHAR2(50)  NOT NULL, 
  PERCENT          NUMBER(5,2)   NOT NULL, 
  CONSTRAINT PK_PRODUCTMIX
  PRIMARY KEY ( PROJECT_LEAD_ID, PRODUCT_TYPE ) )

Basically, it lets me store the different product types used on each project. I have a business rule that says "for each project number, the total percent of products must equal 100 percent".

My question is: how can I implement this when the user enters each product separately? Should I consider moving the logic to the front end instead of using the server to handle it? I would prefer to have the server handle this because I have several front ends.

Thanks in advance for any suggestions.

--
Ken Rachynski
Database Analyst
Evans Consoles
http://evansonline.com/ Received on Tue Feb 08 2000 - 11:43:21 CST

Original text of this message

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