Page 1 of 1

Populate Persistent and Column properties from reversing DDL

PostPosted: Fri Jan 19, 2018 9:42 am
by jbidleman@caci.com
Hello,

I am trying to reverse DDL I have and I was wondering if there is a way to specify or map where information is populated in the table and column specifications. For example, in my DDL, if I have the following statement to create an Oracle comment:

COMMENT ON TABLE XYZ_VENDOR IS 'This is the vendor table';

It will populate 'This is the vendor table' in the Documentation specification for the table property. Is there a way to specify which property contains this description or map to another property instead of Documentation.

Additionally, in my DDL I have ALTER statements to define foreign keys, however I do not see these showing up in either the table or column specifications.

ALTER TABLE XYZ_ADDR_LEVL_VEND ADD FOREIGN KEY (PARN_OF_VEND_ID) REFERENCES XYZ_VENDOR (UIDY);

Ultimately I am trying to create tables by reversing my DDL and display those table and columns properties in a Generic Table.

Thank you!

Re: Populate Persistent and Column properties from reversing DDL

PostPosted: Mon Jan 22, 2018 9:27 am
by gedkvi
Hello,

I think I understood what you are trying to achieve. Please check the comments below.

I am trying to reverse DDL I have and I was wondering if there is a way to specify or map where information is populated in the table and column specifications. For example, in my DDL, if I have the following statement to create an Oracle comment:

This piece of information is non configurable. The COMMENT statement is parsed and transitioned to the model as the documentation of the element(in your case Table). But it is possible to display the documentation in a Generic table.

Additionally, in my DDL I have ALTER statements to define foreign keys, however I do not see these showing up in either the table or column specifications.

Foreign keys, primary keys etc. are reversed to constraint elements. Find them in the Containment tree under the table model. If you can't find them, maybe there was an issue with reverse.
table.png


This is a sample I have used:
Code: Select all
CREATE TABLE supplier
(
  supplier_id numeric(20),
  supplier_name varchar2(100)
);

COMMENT ON TABLE supplier IS 'This is the vendor table';
ALTER TABLE supplier ADD CONSTRAINT supplier_pk PRIMARY KEY (supplier_id);


This is the result:
reversed_sample.png


The sample project file is attached. I hope this covers your case to show all tables with their documentation and their columns.

Sincerely,
No Magic Customer Support