a Adam
on

 

Hello,

We recently began including a Length of "0" in our define files for variables/value level metadata that are completely blank.  During define validation, we are receiving a message saying "Invalid integer value for 'Length'" for these variables.  Is this a bug with Pinnacle, or is there a reason "0" would not be detected as an integer for the Length attribute?

Thanks,

Adam

Forums: Define.xml

j Jozef
on December 4, 2020

In the XML-Schema, the type of "Length" on ItemDef is set to "positiveInteger", which means "1 or higher". Otherwise it would have been "nonNegativeInteger".
There are at least 2 reasons for this:
- the original idea for the Length attribute in the ODM (define.xml is an extension on ODM), is to make it possible to automatically create a relational database from the define.xml (e.g. through "CREATE TABLE" statements). For a relational database, a table column cannot have a length of 0 (VARCHAR(0) or CHAR(0)).
- In SAS Transport 5, a variable cannot have a length of 0 (Lex, please correct me if I am wrong).

I understand your reasoning to set Length=0, maybe it is to avoid the error message that the length is too long for the data. However, that is i.m.o. a stupid rule, which has to do with the fact that FDA reviewers use the files "as is" (on a memory stick?) instead of immediately loading them into a  central database upon receipt, and due to the fact that SAS Transport 5 is a very inefficient file format.

Lex
on December 5, 2020

According to the Define-XML Specification length should be defined as the maximum expected variable length, not the actual collected variable length.

And yes, SAS datasets or XPT files can not have variables with length=0. The only time I actually did see that was when an R package had created a corrupt dataset where blank variables indeed had length=0. That was not valid though, and caused issues with SAS.

Lex

Want a demo?

Let’s Talk.

We're eager to share and ready to listen.

Cookie Policy

Pinnacle 21 uses cookies to make our site easier for you to use. By continuing to use this website, you agree to our use of cookies. For more info visit our Privacy Policy.