Development Tasks Using DB-Library for C
Different development issues exist for applications created for the Microsoft Windows NT, Windows 95, Windows 3.x, or MS-DOS operating system.
For Windows NT-based and Windows 95-based applications:
-
For the Win32®-based versions of the DB-Library DLL, a separate operating system thread may be spawned for each connection that DB-Library makes with SQL Server.
-
The DB-Library functions for the Microsoft Win32 API are stored in NTWDBLIB.DLL. Net-Libraries for Windows NT and Windows 95 are also implemented as DLLs. In addition, the NTWDBLIB.LIB file is an import library containing function definitions.
-
Several unique features of the Win32 API such as asynchronous query processing, memory management functionality, threads, and re-entrancy should be used in your application for optimum performance.
For Windows 3.x-based applications:
-
The DB-Library functions are stored in MSDBLIB3.DLL. Like Win32-based versions of the Net-Libraries, Windows 3.x Net-Libraries are implemented as DLLs. The MSDBLIB3.LIB file contains the import definitions for your application.
-
You can use several different background processing techniques, such as using the PeekMessage loop instead of the GetMessage loop in the WinMain function, to complete long tasks such as query processing.
For MS-DOS-based applications:
-
You must load a Net-Library terminate-and-stay-resident (TSR) utility to communicate with SQL Server.
-
You can select between two memory models: medium (RMDBLIB.LIB or BMDBLIB.LIB) or large (RLDBLIB.LIB or BLDBLIB.LIB).
Other development issues exist, such as how to compile and link your application, that are specific to the development platform and may need to be examined in detail. If you are porting your application from a Windows 3.x-based or MS-DOS-based environment to a Win32-based environment, certain additional issues may exist.
For detailed information about issues related to application development using DB-Library for C, see the Microsoft SQL Server Programmer's Toolkit documentation in the "Database and Messaging Services" section of the Platform SDK.