Resolving error DDTTNS0001 ENTITY-TYPE NOT IN STRUCTURE in Source Language Generation
search cancel

Resolving error DDTTNS0001 ENTITY-TYPE NOT IN STRUCTURE in Source Language Generation

book

Article ID: 279659

calendar_today

Updated On:

Products

Datacom Datacom/DB Datacom/AD

Issue/Introduction

Running a DDUTILTY Source Language Generator command for Elements, but when I use a STANDARD path and START with a specific ELEMENT it generates an error:

   **** ERROR ****  RETURN CODE = DDTTNS0001  ENTITY-TYPE NOT IN STRUCTURE

Here is the input I am using:

-DEF PATH,STANDARD
-END
-UTL LANGUAGE,COBOL
-RPT START,ELEMENT,TESTELM(PROD),STANDARD
-RPT COPY,ELEMENT(PROD),TESTMEM

Environment

z/OS

Datacom/DB 15.1

Cause

The input statements are not specified correctly.

Resolution

At first glance, there are two problems that need to be tidied up here.

1. When you work with an Element, you need to identify the parent of the Element (the Table) in the RPT START. So you might have:

-RPT START,ELEMENT,SOMETABLE.TESTELM    (PROD),pathname

This is needed to identify the proper element, as there could be multiple elements named TESTELM in the Datadictionary. The fact that you got a listing would likely be the result of getting the first element by that name (or the only one if it is unique). Adding the Table name that "owns" the Element makes this more distinct.

As a side note, you should use the same parent explicitly named on the following UTL COPY to have the best results. Like many of the Datadictionary utilities, there are many options available for entity selection, whether you want one item or multiple items. Since you are looking for just a particular Element, you should specify the Table.Element pair on both the RPT START and UTL COPY transactions.

2. The "COPY" transaction is a UTL COPY transaction, not a RPT COPY transaction. Please change it to -UTL COPY ... to be correct.

Additional Information

Information about generating COBOL or other source-language format definitions of Datadictionary entities can be found in the Datacom Core documentation, in the section titled Using the Source Language Generation. You will also find examples of different kinds of entity paths to provide multiple kinds of output.

As always, please contact Broadcom support for Datacom if you have further questions.