Recently a customer has requested information regarding which one to use to connect to HS2 or Impala from .NET application, ODBC or JDBC? I will briefly summarise my findings below:

Both ODBC and .NET are Microsoft products, so it is natural that they will work nicely together. And according to my research, ODBC will also perform better in the case that you do not fetch large amounts of data. Even if you do, the performance difference will not be so great that you will notice the difference. You can have a look at some examples here: Using the Microsoft Hive ODBC Driver in a .NET client

JDBC Drivers are written in Java and designed for Java programs. It can work with .NET, but will require some extra work, and it might make later troubleshooting much harder down the track.

Thrift API is another choice, but the API changes from version to versions, and it adds extra layer between your application and database, so I would expect it will perform worse than ODBC and JDBC counterparts. For more details, please have a look at this page: https://thrift.apache.org/lib/csharp.

So in my opinion, ODBC is the one to go.

One Comment

Leave a Reply

Your email address will not be published. Required fields are marked *