This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
>Organization: PNNL >Keywords: 199606120126.AA17210 Hi Connor, > I'm working at PNNL on the Arm Program and have been trying to > recunstruct a cdf file with ncgen which was converted to text using > ncdump. It appears these two programs are not compatable. I continue to > get a line too long message when going from txt to cdf. I've even tried > to pipe the output from ncdump directly to ncgen. Any suggestions on how > to fix this problem. It's possible there are outputs from ncdump that would cause problems for ncgen, but I didn't think line length was a source of any such problems, because ncgen doesn't read in a line at a time (it only reads in a token at a time with a lex-constructed tokenizer). This may be a bug that no one has encountered before, but to diagnose it and provide a fix, I'll need an example of an ncdump output for which ncgen produces a line too long message. I can find no reference to any such message in the ncgen sources, although there is a message about a "string too long" that occurs if a string longer than 5000 characters is encountered. The limit on string sizes that ncgen can handle is an arbitrary limit set in ncgen.h that can be changed by raising it and recompiling ncgen. It's also possible that the "line too long" problem is caused by a bug in the lex or yacc program used to generate ncgen on your platform, but to determine that I'd still need to have an example that demonstrated the problem and to know on which machine and operating system your ncgen was built. So, can you make available an ncdump output that demonstrates the problem, either via e-mail if it's short, or via FTP if it's large? Thanks! --Russ ______________________________________________________________________________ Russ Rew UCAR Unidata Program address@hidden http://www.unidata.ucar.edu