473,569 Members | 2,458 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

C++ API for SQL Server?

I am thinking of embedding SQL Server express ina (native) C++
application. I am looking for a C++ API for SQE, but cant seem to find
one ...

Is there a (ANSI) C++ API for making native calls to SQLServer
(Express). I am aware of ODBC wrappers, but I'd much rather talk
directly to the database, without having to go through the ODBC layer.
Jun 27 '08 #1
5 10136
On Jun 20, 6:56*pm, Annonymous Coward <m...@home.comw rote:
I am thinking of embedding SQL Server express ina (native) C++
application. I am looking for a C++ API for SQE, but cant seem to find
one ...

Is there a (ANSI) C++ API for making native calls to SQLServer
(Express). *I am aware of ODBC wrappers, but I'd much rather talk
directly to the database, without having to go through the ODBC layer.
Use SQL DMO. Its got a C++ interface. More information is available in
the SQL Server 2000 SDK
Jun 27 '08 #2
sifobo (in**@sifobo.co m) writes:
On Jun 20, 6:56*pm, Annonymous Coward <m...@home.comw rote:
>I am thinking of embedding SQL Server express ina (native) C++
application. I am looking for a C++ API for SQE, but cant seem to find
one ...

Is there a (ANSI) C++ API for making native calls to SQLServer
(Express). *I am aware of ODBC wrappers, but I'd much rather talk
directly to the database, without having to go through the ODBC layer.

Use SQL DMO. Its got a C++ interface. More information is available in
the SQL Server 2000 SDK
Not a very good piece of advice. DMO is a management API, and is not for
general data access as far as I know. On top of that, it is deprecated
and has been replaced with SMO in SQL 2005. SMO is a managed API, so it's
suitable for Anonymous Coward anyway.

--
Erland Sommarskog, SQL Server MVP, es****@sommarsk og.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pro...ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinf...ons/books.mspx
Jun 27 '08 #3
On Jun 20, 11:16*pm, Erland Sommarskog <esq...@sommars kog.sewrote:
sifobo(i...@sif obo.com) writes:
On Jun 20, 6:56*pm, Annonymous Coward <m...@home.comw rote:
I am thinking of embedding SQL Server express ina (native) C++
application. I am looking for a C++ API for SQE, but cant seem to find
one ...
Is there a (ANSI) C++ API for making native calls to SQLServer
(Express). *I am aware of ODBC wrappers, but I'd much rather talk
directly to the database, without having to go through the ODBC layer.
Use SQL DMO. Its got a C++ interface. More information is available in
the SQL Server 2000 SDK

Not a very good piece of advice. DMO is a management API, and is not for
general data access as far as I know. On top of that, it is deprecated
and has been replaced with SMO in SQL 2005. SMO is a managed API, so it's
suitable for Anonymous Coward anyway.

--
Erland Sommarskog, SQL Server MVP, esq...@sommarsk og.se

Books Online for SQL Server 2005 athttp://www.microsoft.c om/technet/prodtechnol/sql/2005/downloads/books...
Books Online for SQL Server 2000 athttp://www.microsoft.c om/sql/prodinfo/previousversion s/books.mspx
Erland, you haven't answered Anonymous's question and called someone's
advice 'not good'. How useful is that!!

I agree SMO has superseeded DMO but Anonymous is looking for somehing
using native C++ and NOT MANAGED C++. So your suggestion is in itself
faulty and useless on various grounds.

Anonymous, I have used C++/DMO in my various projects and it works
just as well for running SQL 2005 as it did for the earlier versions.
Though Redmond has 'stopped' supporting DMO it still hasn't pulled the
plug on it.
Jun 27 '08 #4
max graff (gr****@hotmail .com) writes:
Erland, you haven't answered Anonymous's question and called someone's
advice 'not good'. How useful is that!!
I posted an answer to the original post in a separate article.

And even if I don't know a good answer to the question, and someone posts a
suggestion that I find poor, it can still be helpful if it saves the
person asking from going in the wrong direction.
I agree SMO has superseeded DMO but Anonymous is looking for somehing
using native C++ and NOT MANAGED C++. So your suggestion is in itself
faulty and useless on various grounds.
Anonymous Coward asked something closer to the database than ODBC. If we
overlook the fact that this is difficult to achieve, DMO sits on top of
something (I guess that is OLE DB), DMO is not the answer to that question.
DMO is also a specialised API for management and as far as I know, it is
not intended to be a general API for data access.
--
Erland Sommarskog, SQL Server MVP, es****@sommarsk og.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pro...ads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinf...ons/books.mspx
Jun 27 '08 #5
max graff wrote:
On Jun 20, 11:16 pm, Erland Sommarskog <esq...@sommars kog.sewrote:
>sifobo(i...@si fobo.com) writes:
>>On Jun 20, 6:56 pm, Annonymous Coward <m...@home.comw rote:
I am thinking of embedding SQL Server express ina (native) C++
applicatio n. I am looking for a C++ API for SQE, but cant seem to find
one ...
Is there a (ANSI) C++ API for making native calls to SQLServer
(Express). I am aware of ODBC wrappers, but I'd much rather talk
directly to the database, without having to go through the ODBC layer.
Use SQL DMO. Its got a C++ interface. More information is available in
the SQL Server 2000 SDK
Not a very good piece of advice. DMO is a management API, and is not for
general data access as far as I know. On top of that, it is deprecated
and has been replaced with SMO in SQL 2005. SMO is a managed API, so it's
suitable for Anonymous Coward anyway.

--
Erland Sommarskog, SQL Server MVP, esq...@sommarsk og.se

Books Online for SQL Server 2005 athttp://www.microsoft.c om/technet/prodtechnol/sql/2005/downloads/books...
Books Online for SQL Server 2000 athttp://www.microsoft.c om/sql/prodinfo/previousversion s/books.mspx

Erland, you haven't answered Anonymous's question and called someone's
advice 'not good'. How useful is that!!

I agree SMO has superseeded DMO but Anonymous is looking for somehing
using native C++ and NOT MANAGED C++. So your suggestion is in itself
faulty and useless on various grounds.

Anonymous, I have used C++/DMO in my various projects and it works
just as well for running SQL 2005 as it did for the earlier versions.
Though Redmond has 'stopped' supporting DMO it still hasn't pulled the
plug on it.
Thanks Guys, in the end I settled for SQLAPI which was a light wrapper
around SS (and other dbs). Fitted the bill perfectly - I'm currently
running tests....
Jun 27 '08 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
4567
by: Phil | last post by:
I am using a Pascal like language (Wealth-Lab) on W2K and call this server: class HelloWorld: _reg_clsid_ = "{4E797C6A-5969-402F-8101-9C95453CF8F6}" _reg_desc_ = "Python Test COM Server" _reg_progid_ = "Python.TestServer" _public_methods_ = _public_attrs_ = _readonly_attrs_ =
6
4438
by: Nathan Sokalski | last post by:
I want to set up SQL Server on Windows XP Pro so that I can use the database capabilities of ASP and IIS. I am probably using some incorrect settings, but I am not sure what they are. Here is what I am currently doing: When I run sqlservr.exe I see the following: 2003-12-19 15:51:28.20 server Microsoft SQL Server 2000 - 8.00.760...
9
669
by: Grim Reaper | last post by:
My work let me put SQL Server 7.0 Enterprise Edition on my laptop. I have never setup a server from the beginning, so I am a little new at creating server groups. Alright, I am trying to create a server group. I right click on the "SQL Server Group" and make a name of "TEST" and put in the subgroup of "SQL Server Group". Next, I try to...
0
2798
by: Chris Halcrow | last post by:
Hi I've spent ALL DAY trying to re-install SQL Server 2000 on Windows XP. I continually get the error 'cannot configure server' just at the end of the installation. I've tried the following: - Removing SQL server from 'Program Files' folder following an unsuccessful attempt to re-install, and entirely removing the registry entry...
0
4524
by: Zorba.GR | last post by:
IBM DB2 Connect Enterprise Edition v8.2, other IBM DB2 (32 bit, 64 bit) (MULTiOS, Windows, Linux, Solaris), IBM iSoft Commerce Suite Server Enterprise v3.2.01, IBM Tivoli Storage Resource Manager Express Edition v1.3.2 Win, IBM Tivoli System Automation v1.2.0 Linux, IBM Tivoli Workload Scheduler Virtualized Data Centers v8.2 , other IBM...
2
8377
by: Hazzard | last post by:
I just realized that the code I inherited is using all asp.net server controls (ie. webform controls) and when I try to update textboxes on the client side, I lose the new value of the textbox when submitting the form to update the database. The server doesn't have the client side value any more. It seems to me that as I begin to write the...
2
4906
by: Mike | last post by:
Hi, I am strugling with a simple problem which I can't seem to resolve. I have an asp.net page which contains a server-control (flytreeview, which is a kind of a tree to be exact). The tree is being updated by some other process through remoting. When the page loads, I init the tree, and in my browser I can see the initialized tree. The...
2
6937
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of attending interviews. If you own a company best way to judge if the candidate is worth of it. http://www.questpond.com/InterviewRatingSheet.zip
14
3007
by: Developer | last post by:
Hello All, i have recently installed VS2005 and was trying to install SQL sever 2000. I have Win XP' SP2. But when I tried installing, it only installed client tools and not the database. Can anyone please help me with this as I want to install SQL server and also wouold be grateful, if you can suggest me any workaround to dealwith this...
0
7703
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7926
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7679
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7983
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5223
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3657
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3647
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2117
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1228
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.