DROP TABLE ELEMENT;
DROP TABLE DUMMY_ENTITY;

CREATE TABLE DUMMY_ENTITY (
    ID NUMBER GENERATED by default on null as IDENTITY PRIMARY KEY,
    NAME VARCHAR2(100)
);

CREATE TABLE ELEMENT (
    ID NUMBER GENERATED by default on null as IDENTITY PRIMARY KEY,
    CONTENT VARCHAR2(100),
    DUMMY_ENTITY_KEY VARCHAR2(100),
    DUMMY_ENTITY NUMBER );

ALTER TABLE ELEMENT
  ADD FOREIGN KEY (DUMMY_ENTITY)
    REFERENCES DUMMY_ENTITY(ID);
