kashipai / h2database

H2 Database for reference.
0 stars 0 forks source link

Wrong sort order for JdbcDatabaseMetaData.getIndexInfo #529

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Javadoc[1] specify the order:

NON_UNIQUE, TYPE, INDEX_NAME, and ORDINAL_POSITION

yet H2 has the extra column TABLE_SCHEM:

ORDER BY NON_UNIQUE, TYPE, TABLE_SCHEM, INDEX_NAME, ORDINAL_POSITION

[1] 
http://docs.oracle.com/javase/6/docs/api/java/sql/DatabaseMetaData.html#getIndex
Info(java.lang.String, java.lang.String, java.lang.String, boolean, boolean)

Original issue reported on code.google.com by g...@maginatics.com on 26 Nov 2013 at 5:47

GoogleCodeExporter commented 9 years ago
Hi,

Could you tell me why this is an issue for you?

Technically, you are right, it's a bug as the documentation doesn't match the 
implementation. However, I think the documentation (the official Javadocs) 
should be changed :-)

By the way, many databases require to set a table name (null is not allowed), 
which in my view only makes sense if a schema name is also set.

Original comment by thomas.t...@gmail.com on 27 Nov 2013 at 11:31