Struggling with issue discussed in this thread I was wondering how to extract data types from RFC model dictionary to a new development component. Just simple copy of model dictionary types.
Unfortunately, in NWDS 7.0 right click on data type does not help…
So, what if I want use exactly same data types in other development component project, for example Dictionary project, but don’t want to import rfc model? Here is short workaround for this scenario:
Create development component of desired type.
Open your project with rfc model dictionary and find the package of your logical dictionary simple types (click on one of the simple types for example)
Now look in your project src folder – on your package path you’ll find xml files with data types definitions: dtsimpletype is for simple type, dtstructure for structure and xlf for internatinalization.
Now, you must edit files of data types you want.
Files .dtsimpletype: delete tag DtDataType.LogicalDictionary, for example fo Balmnr remove lines:
<Core.Reference package=”jwozniczak.flight.types” name=”FlightModel” type=”DtLogicalDictionary”/>
and replace package in attribute in the root tag <…package=”my.new.pac” …>. You don’t need to do this.
Files .dtstructure: as above, remove DtDataType.LogicalDictionary, change package in the root tag and if you changed package for simple types then change all package attributes in field references tags
<Core.Reference package=”jwozniczak.flight.types” name=”Bapisign” type=”DtSimpleType”/>
You can make some script for this transformations (like I did), so all this operations take a few seconds.
Next, copy all modified files to your new project to src directory according with package name, so if you changed package to ‘new.pack’ copy files to src/new/pack (or recreate original package, in this example jwozniczak.flight.types). Copy xlf files also.
Reload your project and here you go.
All constraints and data check work perfectly.