Managed c++ vs Unmanaged c++

X

xyu3

Hello,

I'm new to dotnet.

I want to write an app that's communication with a sql server 7
database via ADO.NET. This app need to have fast and stable
throughput. I know that the database access itself will not be the
bottle neck.

The Question is whether i should use Manage c++/C# or Unmanaged C++ to
do it?

If I use Unmanaged c++, what sort of API should I use? for example MFC
or Win32 API or some other Wrappers?

Thanks a lot!
 
J

Jesse McGrew

xyu3 said:
Hello,

I'm new to dotnet.

I want to write an app that's communication with a sql server 7
database via ADO.NET. This app need to have fast and stable
throughput. I know that the database access itself will not be the
bottle neck.

The Question is whether i should use Manage c++/C# or Unmanaged C++ to
do it?

If I use Unmanaged c++, what sort of API should I use? for example MFC
or Win32 API or some other Wrappers?

I suggest sticking to Managed C++. The overhead of switching back and
forth between managed and unmanaged code every time you access the
database will probably outweigh any gains you'd get from using unmanaged
code in the first place.

IMO, you should only use unmanaged code if you have a relatively long,
CPU intensive task that won't require any communication with the managed
parts of your program. For anything less, it isn't worth the context switch.

Jesse
 

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

Top