I am having an issue where JasperServer is bombing out on MySql 5.5 both on the install and when I attempt to insert a Data Type. Table jidatatype has a column name of maxValue which I beleve is a reserved word on 5.5. Has anyone had the same issue or got a workaround?
With MySQL 5.5 going GA yesterday (Dec 15) any plans on fixing this in jasperserver anytime soon? This is unfortunately keeping us from being able to upgrade to MySQL 5.5 and take advantage of all its performance goodies. Thanks</td></tr></tbody></table>
Wondering if this is only applicable to Microsoft Windows MySQL 5.5 users?
The reserved word is MAXVALUE and the table name is maxValue so I think in Linux it should work just fine.
8.2.2. Identifier Case Sensitivity
In MySQL, databases correspond to directories within the data directory.
Each table within a database corresponds to at least one file within the database directory (and possibly more, depending on the storage engine).
Triggers also correspond to files. Consequently, the case sensitivity of the underlying operating system plays a part in the case sensitivity of database, table, and trigger names. This means such names are not case sensitive in Windows, but are case sensitive in most varieties of Unix.
If you have support, you should contact technical support to see when an update for this is expected. I don't know when it's planned for.
In principle it shouldn't be so difficult to change the column to max_value and then update the hibernate mapping to understand that maxValue maps to the column max_value. Give it a try. It would be a great benefit to others if you can let us know how it works for you.
The actual change would be to jasperserver-repository-hibernate/src/main/resources/com/jaspersoft/jasperserver/api/metadata/common/service/impl/hibernate/persistent/RepoDataType.hbm.xml
Just change the name of the column to something MySQL 5.5 likes:
<property name="minValue" type="serializable"/>
<property name="maxValue" column="max_value" type="serializable"/>
The js-create.ddl script (which is failing for you now) will be generated with the new column name when you rebuild.
Before any of this gets rolled into the real product we need to make sure it works (duh!) but we also need to figure out any upgrade issues. You may not care about that side of things, so you could try it more quickly.
P.S. Credit goes to Bob T for the code sample.
FYI I opened an issue on this a while back. I also made a similiar change but instead of changing the column name, simply had hibernate quote the column (the brackets are the platform independant way to tell hibernate to quote the column).
What's nice about this approach is no schema changes are necessary and hibernate knows how to quote a column in any database server it is connecting to.
<property name="maxValue" column="[maxValue]" type="serializable"/>
Post Edited by ahagopian at 02/22/2011 19:54