Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-6187

GroovyResultSet Proxy not working with Object methods

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.8.9, 2.0.8, 2.1.3
    • 2.1.5
    • SQL processing
    • None

    Description

      When using eachRow the following works fine (as do calls through getAt etc. or getMetaClass()):

      sql.eachRow("select * from PERSON") { println it }
      

      but accessing the methods from Object or DGM methods like dump() fail. All these fail:

      sql.eachRow("select * from PERSON") { println it.getClass() }
      sql.eachRow("select * from PERSON") { println it.toString() }
      sql.eachRow("select * from PERSON") { println it.dump() }
      sql.eachRow("select * from PERSON") { println it.hashCode() }
      

      with messages like:

      groovy.lang.MissingMethodException: No signature of method: groovy.sql.GroovyResultSet.toString() is applicable for argument types: () values: []
      Possible solutions: toString(), toString(), notify()
      

      Attachments

        Activity

          People

            melix C├ędric Champeau
            paulk Paul King
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: