Friday, May 22, 2020

How to create and link interactive grid report with modal form

Trigger:
=====
create or replace TRIGGER  "DEMO_CUSTOMERS_BIU"
  before insert or update ON demo_customers FOR EACH ROW
DECLARE
  cust_id number;
BEGIN
  if inserting then
    if :new.customer_id is null then
      select demo_cust_seq.nextval
        into cust_id
        from dual;
      :new.customer_id := cust_id;
    end if;
END;
/


Interactive Report Query:
==================
select customer_id,cust_last_name ||','||cust_first_name customer_name,
cust_street_address1|||decode(cust_street_address2,null,null,','||cust_street_address2)
customer_address,
cust_city,cust_state,cust_postal_code
from demo_customers

No comments:

Post a Comment