{"action":"opened","issue":{"url":"https://api.github.com/repos/dieselpoint/norm/issues/10","labels_url":"https://api.github.com/repos/dieselpoint/norm/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/dieselpoint/norm/issues/10/comments","events_url":"https://api.github.com/repos/dieselpoint/norm/issues/10/events","html_url":"https://github.com/dieselpoint/norm/issues/10","id":113645638,"number":10,"title":"Problem with metaClass object when using norm in Groovy","user":{"login":"jeancarlozapata","id":1937003,"avatar_url":"https://avatars.githubusercontent.com/u/1937003?v=3","gravatar_id":"","url":"https://api.github.com/users/jeancarlozapata","html_url":"https://github.com/jeancarlozapata","followers_url":"https://api.github.com/users/jeancarlozapata/followers","following_url":"https://api.github.com/users/jeancarlozapata/following{/other_user}","gists_url":"https://api.github.com/users/jeancarlozapata/gists{/gist_id}","starred_url":"https://api.github.com/users/jeancarlozapata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeancarlozapata/subscriptions","organizations_url":"https://api.github.com/users/jeancarlozapata/orgs","repos_url":"https://api.github.com/users/jeancarlozapata/repos","events_url":"https://api.github.com/users/jeancarlozapata/events{/privacy}","received_events_url":"https://api.github.com/users/jeancarlozapata/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-10-27T18:04:48Z","updated_at":"2015-10-27T18:04:48Z","closed_at":null,"body":"First of all, great library. Small, easy to understand and use. Thanks for working on it.\r\n\r\nI'm trying to run the next Groovy script using ```norm``` (note that I've ran successfully the \"same\" code on a Java project):\r\n\r\n```groovy\r\n@GrabConfig(systemClassLoader=true)\r\n@Grab(group='mysql', module='mysql-connector-java', version='5.1.37')\r\n@Grab('org.eclipse.persistence:javax.persistence:2.1.0')\r\n@Grab('com.dieselpoint:norm:0.8.1-rc2')\r\n  \r\nimport com.dieselpoint.norm.Database;\r\nimport com.dieselpoint.norm.Query;\r\nimport com.dieselpoint.norm.sqlmakers.MySqlMaker;\r\n\r\nimport java.util.List;\r\nimport javax.persistence.*;\r\n\r\n@Table(name=\"data\")\r\nclass Data {\r\n  @Id\r\n  @GeneratedValue\r\n  long id;\r\n  String name;\r\n  long value;\r\n\r\n  public Data() {\r\n    this.id = 0;\r\n    this.name = \"\";\r\n    this.value = 0;\r\n  }\r\n}\r\n\r\nSystem.setProperty(\"norm.dataSourceClassName\", \"com.mysql.jdbc.jdbc2.optional.MysqlDataSource\");\r\nSystem.setProperty(\"norm.serverName\", \"localhost\");\r\nSystem.setProperty(\"norm.databaseName\", \"mytablename\");\r\nSystem.setProperty(\"norm.user\", \"root\");\r\nSystem.setProperty(\"norm.password\", \"s0meD1ficultPassw0rd\");\r\n\r\nDatabase db = new Database();\r\ndb.setSqlMaker(new MySqlMaker());\r\n\r\nList<Data> data = db.where(\"name=?\", \"SayMyName\").results(Data.class);\r\nfor(Data p : data) {\r\n  System.out.println(p.id + \": \" + p.name + \" => \" + p.value);\r\n  System.out.println(\"****\");\r\n}\r\n```\r\nWhen I try to run it from the command line, the next error occurs:\r\n\r\n```\r\nCaught: com.dieselpoint.norm.DbException: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'metaClass' in 'field list'\r\ncom.dieselpoint.norm.DbException: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'metaClass' in 'field list'\r\n        at com.dieselpoint.norm.Query.results(Query.java:215)\r\n        at com.dieselpoint.norm.Query$results.call(Unknown Source)\r\n        at test-norm-groovy-error.run(test-norm-groovy-error.groovy:37)\r\nCaused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'metaClass' in 'field list'\r\n        at com.mysql.jdbc.Util.handleNewInstance(Util.java:404)\r\n        at com.mysql.jdbc.Util.getInstance(Util.java:387)\r\n        at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:941)\r\n        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3870)\r\n        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3806)\r\n        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2470)\r\n        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2617)\r\n        at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2550)\r\n        at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1861)\r\n        at com.mysql.jdbc.PreparedStatement.executeQuery(PreparedStatement.java:1962)\r\n        at com.zaxxer.hikari.proxy.PreparedStatementProxy.executeQuery(PreparedStatementProxy.java:52)\r\n        at com.zaxxer.hikari.proxy.HikariPreparedStatementProxy.executeQuery(HikariPreparedStatementProxy.java)\r\n        at com.dieselpoint.norm.Query.results(Query.java:186)\r\n        ... 2 more\r\n```\r\n\r\nThis is due to Groovy's ```metaclass``` interface implementation for POGOs. Is there any way to circumvent this error?\r\n\r\nI prefer using Groovy for simple scripts, and norm is a great fit for them. Norm works great for me in Java but I need to set up a whole project to use it in Java :disappointed: \r\n\r\nThanks!"}}