 |
|
SQL Server Tips by Burleson |
Implementation using framework for XP_NETSEND
To implement the XP, we will use the XP++ framework to implement the
boilerplate code required. We follow the procedure for adding XP++
support to our project as described in the XP++ chapter.
The code required to setup the basic XP framework for XP_NETSEND is
contained in the module “XP_NETSEND.cpp” and contains the standard
code required by the XP++ framework to create an XP. The DLL exposes
3 XP’s using the following XP++ code:
IMPLEMENT_XP(XP_NET_SEND, CNetSendExtendedStoredProcedure)
IMPLEMENT_XP(XP_NET_ADDNAME, CNetAddNameExtendedStoredProcedure)
IMPLEMENT_XP(XP_NET_DELNAME, CNetDeleteNameExtendedStoredProcedure)
Each of the 3 classes which implement the XP's are implemented in
the module “XP_NETSENDProcs.h/cpp”.
The above book excerpt is from:
Super SQL
Server Systems
Turbocharge Database Performance with C++ External Procedures
ISBN:
0-9761573-2-2
Joseph Gama, P. J. Naughter
http://www.rampant-books.com/book_2005_2_sql_server_external_procedures.htm |