We explored several different strategies on how to best implement the comment fields. The final implementation of the comment fields involved a two-tiered hierarchy of SCL Lists. Our goal was to be able to store all the comment fields for a given observation into a single catalog entry. We accomplished this by creating a 'master' SCL list and then populating it with multiple sub-lists.
Each sub-list contained the comments for a single field. We used 'Named' Lists so that the name of each sub-list corresponded directly
to the name of each comment field (which was an 'Extended Text Entry' widget on the AF screen). Another advantage of having all the comments for an observation stored in a single catalog entry was that we could programmatically assign a descriptive label to the catalog entry. This allowed the user or analyst to quickly look at the catalog and determine if any comments had been added for a particular task.
Another important feature of this system involved designing a method for linking the exposure data, which were stored in a SAS dataset, with the comments that were stored in a SAS catalog entry. The objective was to create a simple, but permanent, link between each observation in the SAS dataset and its corresponding comment fields in the catalog entry. To accomplish this, we created an 8-character field that was saved as a variable in the SAS dataset and was also used as the entry name in the SAS catalog (see Figure 1).
This variable was constructed using the algorithm below.
commval = 'C' || left(put(ranuni(0)*10000000,7.));
This value was then used as part of the catalog entry name using code similar to the line below.
outslist = 'library.tasks.' || commval || '.slist';