title: Groovy Sql to fetch all columns
body: <p>I am using Groovy Sql to fetch results. This is the output from my Linux box.</p>
  
  <pre><code>%isql -U abc -P abc -S support
  1&gt; sp_configure 'number of open partitions'
  2&gt; go
   Parameter Name                 Default     Memory Used Config Value    Run Value    Unit                 Type
   ------------------------------ ----------- ----------- ------------  ------------ -------------------- ----------
   number of open partitions              500        5201         5000          5000 number               dynamic
  
  (1 row affected)
  (return status = 0)
  1&gt;
  </code></pre>
  
  <p>I am using groovy code</p>
  
  <pre><code>def sql = Sql.newInstance("jdbc:abc:sybase://harley:6011;DatabaseName=support;",dbuname,dbpassword,Driver)
  sql.eachRow("sp_configure 'number of open partitions'"){ row -&gt;
          println row.run_value
      }
  </code></pre>
  
  <p>but it gives me</p>
  
  <pre><code>Exception in thread "main" java.sql.SQLSyntaxErrorException: [abc][Sybase JDBC Driver]Invalid column name: run_value
  </code></pre>
  
  <p>So it says it cannot get the speciied columns, is there a way it can fetch the result and display?</p>
  
  <p><strong>Update</strong></p>
  
  <p>I used the below code</p>
  
  <pre><code>sql.eachRow("sp_configure 'number of open partitions'"){ row -&gt;
              println row
      }
  </code></pre>
  
  <p>and it gives me </p>
  
  <pre><code>[Parameter Name:number of open partitions     , Default:        500, Memory Used:       5201, Config Value:        5000, Run Value:        5000, Unit:number              , Type:dynamic   ]
  </code></pre>
  
  <p>How can I get <code>Run Value</code>? (since it has a space in it)</p>
  
  <p><code>row.Run Value</code> will not work for sure</p>