Implementing an ODBC driver for a database written in C#...

  • Thread starter Thread starter redefined.horizons
  • Start date Start date
R

redefined.horizons

I am working on a specialised database that is written in C#. I would
like to create an ODBC driver that allows external programs to conenct
to my database. Is is possible to support ODBC in a high-level .NET
language like C#? Or will I need to somehow wrap support for an ODBC
driver written in the C programming language with .NET interoperability
tools?

Can someone point me to some documentation about implementing an ODBC
driver via C#, if this is possible?

Thanks,

Scott Huey
 
Scott,

You will have to use a stub written in unmanaged code to provide an ODBC
driver. The reason for this is that ODBC requires the providers to export
functions from a dll, something that C# can not produce.

I have to ask, why ODBC? I mean, can you not use OLEDB even? You can
write an OLEDB provider in .NET, since you can implement the required
interfaces using COM interop.

Hope this helps.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top