Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.
Originally posted by: j thomasI've got two nodes based on a JDBC Query to the same database.
The first one outputs column headings if no records are returned.
The second one does not output any column headings if no records are returned. I think this is causing the error 'Premature EOF trying to read header line' that I then encounter when trying to use output from the second JDBC Query.
I can't see any difference between the two nodes except for the select statements. They both explicitly select column names (first thing I tried was to replace select * with a column list in the problem node). They use different tables - the first query takes some columns from several joined tables whilst the second selects all columns from a single table.
I tried creating a static data node for the column definitions and unioning the output with a cat node as per this thread
http://community.mda-data.com/showthread.php?t=159; I tried passing the output through a filter; I tried a metadata node to check there is at least one record but each time I get the Premature EOF error.
Is there any way to force the column headings into the output or to detect there is no header line and handle it somehow without the error getting thrown?
Thanks in advance.