Skip to Content
0

attribute generation

Jun 21, 2017 at 03:11 PM

26

avatar image
Former Member

Is there a way to NOT generate an attribute in the physical model? In other words, in the logical model I have an attribute in an entity. But in the physical model, I DO NOT want that to be part of the table.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Phillip Lam
Jun 21, 2017 at 04:19 PM
0

You can do this in two ways:

1) In LDM, create Extension. In the extension, create pre-transformation for EntityAttributes.

Then Enable the transformation. This is the screenshot:

2) Generate PDM from LDM. Open the pdm, go to Tools->Execute Commands->Edit/Run Script. Execute the following code:

set tables=activemodel.tables
for each tbl in tables
for each col in tbl.columns
col.delete
next
next


ctempcapture.png (41.3 kB)
Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Jun 21, 2017 at 04:44 PM
0

There are many tables, but I want to suppress two columns only from one of the many tables, let's say table Stategy

Share
10 |10000 characters needed characters left characters exceeded
Phillip Lam
Jun 21, 2017 at 08:25 PM
0

If you decide to use pre-transformation, you can create an extended attribute for EntityAttribute. If you want to remove an attribute, set its extended attribute to true.

For example, I create RemoveColumn

This is the code in transformation:

Then you open ldm. Open an entity. Open an attribute's property. In Extended Attribute tab, set the value to true.

If you decide to write script, you can put the table name and the column you want to delete in a file. The script read the file and does its job.


ctempcapture.png (37.2 kB)
ctempcapture1.png (42.7 kB)
ctempcapture2.png (53.3 kB)
Share
10 |10000 characters needed characters left characters exceeded