Re: DatabaseMetaData.getImportedKeys problem
Posted by: Mark Matthews
Date: March 31, 2005 03:58PM

roger wrote:
> We have a strange problem reported from one of our
> users using DbVisualizer.
>
> 1) The problem appears when running the MySQL DB
> on Mac OS X. All table names in the actual
> database starts with an uppercase letter i.e
> Brand, Client, etc. If we now execute
> DatabaseMetaData.getImportedKeys() then it gives
> the following result with all letters in the the
> PKTABLE_NAME column in lowercase while the
> FKTABLE_NAME shows the correct spelling.
>
> PKTABLE_NAME
> -------------------
> account
> account_notes
> analytic
> brand
> client
>
> FKTABLE_NAME
> -------------------
> Account
> Account_Notes
> Analytic
> Brand
> Client
>
> 2) Running the very same MySQL DB on a Linux box
> using the same JDBC version gives the following
> correct result:
>
> PKTABLE_NAME
> -------------------
> Account
> Account_Notes
> Analytic
> Brand
> Client
>
> FKTABLE_NAME
> -------------------
> Account
> Account_Notes
> Analytic
> Brand
> Client
>
> Why this deviation?
>
> Roger Bjarevall
> Minq Software


Roger,

The driver basically parses the output of 'SHOW CREATE TABLE' (at least until all of INFORMATION_SCHEMA will be implemented in MySQL-5.0). I'd have to see the output of that command for each of the tables in question. My guess is that the server isn't being consistent with the capitalization between the tables and the foreign key constraints it writes out as a response to the command.

-Mark

Mark Matthews
Consulting Member Technical Staff - MySQL Enterprise Tools
Oracle
http://www.mysql.com/products/enterprise/monitor.html

Options: ReplyQuote


Subject
Written By
Posted
Re: DatabaseMetaData.getImportedKeys problem
March 31, 2005 03:58PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.