From: <leg...@at...> - 2003-08-28 12:39:27
|
The following issue has been updated: Updater: Dylan Etkin (mailto:de...@cs...) Date: Thu, 28 Aug 2003 7:38 AM Comment: This has been updated to be more efficient for table metadata lookups. I have put in commented out code that will speed up the initSequeneces method iff hibernate only ever cares about sequences named "hibernate_sequence". I haven't looked at the code enough to know if this is so. Changes: Attachment changed to schemaUpdate.patch --------------------------------------------------------------------- For a full history of the issue, see: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-278&page=history --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-278 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-278 Summary: calling Configuration.generateSchemaUpdateScript always generates create sql Type: Patch Status: Unassigned Priority: Major Project: Hibernate2 Components: core Versions: 2.1 Assignee: Reporter: Dylan Etkin Created: Thu, 21 Aug 2003 7:23 AM Updated: Thu, 28 Aug 2003 7:38 AM Environment: postgres, oracle, mysql Description: The call to generateSchemaUpdateScript was always creating the create sql when running in postgres. The problem was with the case of the table name and an uppercase version being sent as a parameter to the DatabaseMetaData. The sequences were also always comming back as in need of a create since none of the dialects implement the getQuerySequencesString method. The fk's were not matching on their hashed name since the metaData name had more info than just the display name. I have fixed these issues and tested it on postgres, oracle, and mysql. It seems to work for me so I am submitting the patch. I am by-passing the call to getQuerySequencesString and just using the metaData to get all sequences if they exist. There is an outstanding issue with mysql where the call to getIndexIterator in the Table class returns an empty iterator so the index create statements are always generated. I have not looked into this. Hope this helps. --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |