Reputation: 1272
I am using ms excell as database in java program.
but i am getting following error.
java.sql.SQLException: [Microsoft][ODBC Excel Driver] External table is not in the expected format
I am not getting why this exception occurs.
Upvotes: 0
Views: 8477
Reputation: 5836
Oh, that's the one I got quite often. It's one of many reasons why I'm switching to Apache POI
Here is the approach I got from our internal Wiki. Maybe it will help:
Make sure you are using the correct ODBC driver for the version of excel (i.e. Excel 2003 or Excel 2007) you are trying to open. NOTE: The error in this instance "SQLDriverConnect failed :[Microsoft][ODBC Excel Driver] External table is not in the expected format.", was caused by selecting an Excel 2003 ODBC Driver to open up an Excel 2007 file.
To Configure an ODBC Excel Driver do the following:
Instead of trying to reconfigure your ODBC settings, you can also open the Excel file directly in Statistics.
To open up your Excel file directly in Statistics, launch Statistics and do the following from the menus in the Statistics Data Editor Window:
If you can provide more information about what are you doing and how, maybe then I can give you some more detailed information.
Upvotes: 1