Oracle Legacy Tables

We use Oracle.     We have several existing tables that follow this model.


CREATE TABLE SCHEMA.TABLE_NAME1
(
  TABLE_NAME1_ID        NUMBER                  NOT NULL,
   CREATED_DT            DATE                       NOT NULL,
   OTHERVALUE           VARCHAR2(10)
);

ALTER TABLE SCHEMA.TABLE_NAME1 ADD (
  CONSTRAINT TABLE_NAME1_PK
  PRIMARY KEY
  (TABLE_NAME1_ID);


CREATE SEQUENCE SCHEMA.TABLE_NAME1_SEQ
  START WITH 1;

CREATE OR REPLACE TRIGGER SCHEMA.TABLE_NAME1_BIR 
BEFORE INSERT ON "SCHEMA"."TABLE_NAME1" FOR EACH ROW
BEGIN
    SELECT  TABLE_NAME1_SEQ.NEXTVAL
      INTO  :NEW.TABLE_NAME1_ID
      FROM  dual;
   :NEW.CREATED_DT := SYSDATE;
END;

Basically where we have Sequence that populates the ID Value, and set the Created_dt in the trigger.

We then us the oracle "RETURNING INTO" to get back the values that were populated by the trigger.  http://docs.oracle.com/cd/B19306_01/appdev.102/b14261/returninginto_clause.htm

Does Aurelius support NOT NULL fields, that are populated by triggers?   I can't seem to figure out what mapping I would use. 


In this case you would have to use an Assigned generator (which means manual) and then after saving you should do a Refresh in the object to get the value generated by the server.