vc connect to sqlserver

How to connect to sqlserver using vc++
0
5/20/2008 2:18:50 AM
vc.mfc 33608 articles. 0 followers. Follow

2 Replies
858 Views

Similar Articles

[PageSpeed] 58

Using what library?
			joe

On Mon, 19 May 2008 19:18:50 -0700 (PDT), Rajendra.Arayur@gmail.com wrote:

>How to connect to sqlserver using vc++
Joseph M. Newcomer [MVP]
email: newcomer@flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
0
newcomer (15974)
5/20/2008 2:24:20 AM
<Rajendra.Arayur@gmail.com> ha scritto nel messaggio 
news:32bc726d-c732-4955-b81a-b82c2c2d8e22@a9g2000prl.googlegroups.com...
> How to connect to sqlserver using vc++

Hi Rajendra,

as Joe correctly points, you have several options and several libraries and 
technologies to connect to a database.

You can use OLE DB Templates (a set of C++ template classes, part of ATL 
library).

http://msdn.microsoft.com/en-us/library/8k76sd16(VS.80).aspx

And there are also multiplatform solutions, like SQLAPI++:

http://www.sqlapi.com/

Moreover, I believe that if you go to sites like SourceForge 
(http://sourceforge.net) you will find several other libraries...

I don't know if it is possible to use .NET classes (like those in the 
namespace System.Data.SqlClient) using C++/CLI...

HTH,
Giovanni


0
5/20/2008 8:03:02 AM
Reply:

Similar Artilces:

Formula to connect cells in different worksheets?
How do i link an employee to their wage automatically? Is it possible to enter in my employee's name and hours, and have it automatically calculate their wage? I have all my employees wages in another worksheet right now. At this time I go to my job record worksheet I enter in my employee, enter the hours type =left arrow tab to worksheet with wages and click on the employee then hit enter, this gives me there total wage. I am trying to see if I can program the name and wage together somehow, that when I do type the name it calculates with the hours and gives me a total. tb Use ...

Exchange 2003 connects Port 1149 / 3045 / 1355 ???
Helo NG, the Firewall Log reports several Drops from our Exchange Server connecting to the Internet. The Ports are 1149 / 3045 /1355 /1083. Have you any Suggestion ? thx Peter ...

To stop a pop up LDAP Directory Connection details?
Each time I start outlook a pop up appears "Microsoft LDAP Directory Connection Dteails. How to stop this pop up? Control Panel->Mail Icon->Directories - Address Book->View or Change->Change. Remove the LDAP service. Back up and install the Outlook Address Book service. I presume this is an upgrade from Office/Outlook 2000? A common issue. -- Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. How to ask a question: http://support.microsoft.com/KB/555375 After furious head scratching, Parf asked: | Each time I start outlook ...

UML Tool for developing with MFC/VC++ 6
Hi I am looking for an UML tool that is tightly integrated into Visual Studio 6 in a project that uses MFC. The tool must have: class diagrams, sequence diagrams and statecharts. It should generate code from an UML model, and it should synchronize with the generated code while developing, i.e. you should be able to develop the uml model or the code and the whole model is updated correctly. I do not need to generate code from statecharts, but statecharts should be visualized. The tool may cost more than a few hundred dollars, (if it is worth that money :-). Thanks for any hints Stef...

How to display HTML HELP from VC++ when compiling for WIN64/Unicode
Hi all, My first post to this group, please be nice :-) I'm migrating my Visual Studio 6 C++ (MFC) projects to Visual Studio 2005. In my projects I launch HTML Help using the following notation: ::HtmlHelp(0, NULL, HH_DISPLAY_TEXT_POPUP, (DWORD)&popup); having previously declared HH_POPUP popup; In some case I instead use: ::HtmlHelp(0, cHelpFilePath:"::/changetimestamp.htm", HH_DISPLAY_TOPIC, NULL); This all works fine in VS2005 too, no problem. EXCEPT....when I compile for WIN64 and Unidocde! When I compile for WIN64 (x64) I get the following error: TipDlg.obj:...

GFI MailArchiver Outlook Connection
We are looking at this software as an archiving option instead of upgrading the Exchange server for now. One problem is we would like the users to have access to their stores. We have managed to add a folder to their Outlook profile and then made the default homepage the GFI web interface but this requires either a visit to each workstation or step by step instructions for the individual user. I know that the users can just have a shortcut to the web interface, but it was requested that there be one app not two. Does anyone know of an easier way to set this up? Thanks in advance. ...

POS 2.0 Database Connection has been lost......
At closing, while trying to settle the credit card transactions, we get this message: "The database connection has been lost. When you have resolved the problem, click Reconnect. If successful, POS will reopen, but unsaved work will be lost." This has happened a couple of times in a row and now we find out that customers have been charged multiple times ! The only references I could find in this forum tell me to take my debit card pad off and to restart the SQL service. This hasn't helped, still cannot settle. Anybody any pointers ? Thx I should add that the database i...

Connecting to HQ Manager via IP address
Is it possible to connect to HQ from outside the HQ network? I would like to be able to specify the IP and port like you do in HQ Client to enable me to run HQ Manager from a store location or home office to connect to the HQ database. Any suggestions? -- Dan Rishworth hi Dan, yes it is possible the thing you need is static IP , you can use the ADSL /DSL connection for it and request your ISP to give you dedicated IP that IP you can put to your HQ server (make sure give some security to HQ machine) and then from anywhere in this world you can access your HQ by giving the public IP ...

cannot connect
I'm using wireless between XP PC and this 7 laptop. The XP computer can connect to the laptop but I can't connect the laptop. I see under network that the public profile is used - how do I change this to private? Thanks, I, best advice is to get a router. it is much safer to have a router between you and your broadband Internet connection. some larger ISPs even give out free routers. who provides your Internet service? On Sat, 11 Sep 2010 17:06:52 +1200, "Jason" <jallen@hotmail.com> wrote: >I'm using wireless between XP PC and this 7 laptop. ...

help! laptop w/vista can't get connection
Hi there - I'm so technilogically backwards, I hope I'm in the right forum! Problem: Just moved, and when I did, my internet company (verizon) sent me a new wireless router. THe one I'd used was one I'd purchased, and never had a problem with, but they suggested I get this one. No worries. So, I set it up and have internet on my main computer. However, I cannot set up my laptop to get the internet. I used to live in a house, so there wasn't a worry about other connections nearby. Now I've downsized to an apartment and the only connections I can see are t...

problem with tabing in VC++ OCX
Hello All, I have an ocx control written in visual c++. When I am using this ocx control in Internet explorer, the tab key is not working with any of the UI controls inside the ocx. The dialog inside the ocx has the tab order set properly also. Initially when the page is loaded, the focus comes to the first edit box in ocx. On pressing the TAB key in keyboard, it goes directly to address bar in IE and will never get the focus back on the ocx. Anybody know why this behavior?, and any work around for this?. Thanks in advance, Sujith Manuel. ...

InvalidSecurityContextException trying to connect to WebService
Anyone know, why this might be the case? The user running the client has been setup as supersuer in the Dynamics Security Console Exception type: Microsoft.Dynamics.Security.InvalidSecurityContextException Exception message: Microsoft.Dynamics.Security.NonExistentSecurityObjectException : The security object does not exist. Key = 1 SecurityContext: ApplicationKey: 25cc1a21-2cc4-4b13-a1c8-eea186fb688a ScopeKey: 1 User: IGUSNJEWACCT3V\BizTalkUser Action: GetRoles Input parameters: <RequestObjects> <string>IGUSNJEWACCT3V\BizTalkUser</string></RequestObjects> St...

Unable to Connect to database #2
I'm getting this error when my second register trys to connect to the server When I test the connection under the store adminstrator I get the following response Error #2147467259 [DBNETLIB]{ConnectionOpen(PreloginHandshake()).]General network error. Check your network documentation.(Source:Microsoft OLE DB Provider for SQL Server) (SQL State: 08001) (NativeError: 11) No Help Files available I have on both registers two users one is computer admin the other Limited (same names & passwords). Only if I login as admin on the register that is the server (register 1) I can connect ...

Connection was dropped due to an SMTP protocol event sink
Hello All, Starting about two weeks ago, our Exchange 2003 server started generating a “The connection was dropped due to an SMTP protocol event sink” error, when viewing the Queues, on email sent to AOL, just AOL. A few other domains also fail to send email with the error “The remote server did not respond to a connection attempt” Other domains however, continue to send without error. We are running this on Windows Server 2003. I’ve seen this error all over other boards, but not a mention from Microsoft. Problem is, the solutions presented by non-Microsoft sources fail to resolve...

OL 2003 Connection
It is apparent from this newsgroup and other MS tech support areas that there is a problem connecting to Exchange Server 2000 with OL 2003. I have a 512k ADSL line and managed to get connected first time (LAN router connection), however, I have now wasted many hours of my time (which I won't be able to charge for) trying to get OL2003 to connect to the same (remote) Exchange Server 2000 over LAN routed ISDN without success. It would appear that no matter how long I set the connection timeout in OL2003 to be it times out after approx 30 secs. The ISDN connection is "live" to the ...

Connection Filtering Tab Greyed out
We are in a mixed mode Exchange Org. I am trying to configure Connection Filtering on my Exchange 2003 SP1/Windows 2003 server but when I click on the Connection Filtering tab I get an error and the options are grayed out. The error message references article 818482 but the article doesn't give a work around or solution that works; it states to use Exchange 200O System Manager to do the filtering but E2k ESM doesn't show the Connection Filtering tab. Any ideas? Regards, Brian ...

Informatica Connect to Excel workbook
READER_1_1_1> DBG_21438 Reader: Source is [Romania:Romania], user [PMNullUser] I'll try to connect to an excel workbook with different country sheets containing data, which I want to load into our DWH. Now I'm getting the following error : READER_1_1_1> Fri Dec 03 09:29:24 2004 READER_1_1_1> RR_4036 Error connecting to database [ [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified Database driver error... Function Name : Connect Database driver error... Function Name : Connect Database Error: Failed to connect to database using user...

Outlook "connecting to" pop-up
My client is running Outlook on Vista computers in a domain with a SBS2008 server. Every time they start Outlook, they get a pop-up with "Connecting to remote.ajax.com" and prompting for a username/password. remote.ajax.com is the external URL pointing to their IP address. Canceling it seems to cause no further problems. Very annoying, and I've search extensively and find no solutions. Can anyone help? Thanks in advance! -- IT Consultant Heartland Computer chaswood wrote: > My client is running Outlook We are to guess which version of Outloo...

My MFC VC++ app is crashing within ProcessShellCommand
The application is running in debug mode and it crashes on a Win2K production server both when running interactively (by double-clicking on the exe when I, an administrator on the box, am logged on to the server) and as a service under a local account (which is part of the Admin group also). However, If I run it under the LocalSystem account everything is fine. Also, everything is fine if I run de application interactively through a Terminal Server session or through Remote Debuging from the Visual Studio environment running on my laptop. The application works fine both interactivle ...

Business Portal connecting to Terminal server with unusual port nu
Hi. I am trying to connect my Business Portal to our terminal server. For security reasons we are using an unusual port number (54903). When we put in just the Terminal server name in the Business Portal area in the site setting, general area for Terminal server we get a 516 error (winsock socket connection failure). if I put in the name of a different server, it works ok (opens a terminal server window). how do I have it redirect to the proper Terminal server with the unusual port number? ...

What is the point of Document Connection?
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel What exactly is the point of Document Connection? I have an Office Live account but I cannot delete items from the workspace from connection, nor can I add folders inside connection to my workspaces. codywilliams@officeformac.com wrote: > What exactly is the point of Document Connection? I have an Office > Live account but I cannot delete items from the workspace from > connection, nor can I add folders inside connection to my workspaces. It allows you to access and modify files on Office Live. It does not e...

Move files that OLE Links are connected to
We are in a network environment. We have run out of space on our main finance server and are going to purchase a new one. However I have over 1000 OLE links linked to the maxed out server. What is going to happen to the OLE links when we move the original files to a new server? Am I going to lose everything? Is there a way that we can run a script of some kind to change the file extension in the OLE link to the new server name without disrupting/losing the links? Jen, Try copy your ole directory in the old server and put it to the new server. After that, change your dex.ini file...

Wireless Connection
Toshiba Laptop w/ XP: I'm not showing any wireless connections in my "Choose a wireless network" screen. I can not update the driver from the device manager, this made me just uninstall the driver and reinstall from Intel's site. After doing this, it works, brings up all connections in my area and I can connect to one of them. But when I turn the computer off and turn back on, whether immediately or the next morning, there's no wireless connections anywhere. It's like there's no wireless network adapter available. I have retried the uninstall-reinstall...

Serial Letter- Connection with Excel database
Hi there, i want to print about 200 adresses on etiquettes. those are in an excelfile. the probl. is that I have on data on a whole page. What can i do, that every etiquette is filled with a different data? Thanks forward Vicky -- Vic1978 ------------------------------------------------------------------------ Vic1978's Profile: http://www.excelforum.com/member.php?action=getinfo&userid=28708 View this thread: http://www.excelforum.com/showthread.php?threadid=492986 Do you mean envelopes? If you do, you may want to use MSWord's mailmerge for the printing of the envelop...

Connect to the internet wizard fails sbs 2003
Hi, I hae taken oer another SBS server. When running the connect to the internet wizard it fails on the firewall configuration. I have had to go into IIS and change access permissions on the exchange/remote sites in order to get these working. It also fails to create the new certificate matching the external host name leaving the one in the place which is completely wrong. How can I troubleshoot this issue. Thanks Simon Hi Simon: the CEICW creates a log file when it runs, but it is appended to each time you run the wiz so it gets pretty cumbersome. I would find that file a...