Information générale
Forum:
Microsoft SQL Server
Catégorie:
Stored procedures, Triggers, UDFs
Titre:
Writing SQL Server SPs using VFP
Hi,
As anyone here ever tried (and succeeded) writing SQL Server Strored Procedures using VFP? Any version of VFP would do.
For example, here are the requisites (according to BOL) of writing such procedures:
Must have a prototype with the following structure:
SRVRETCODE xp_extendedProcName (SRVPROC *);
Use the following compiled library:
Opends60.lib
Finally, use a header file (I know this is possible but the code in it is pure C):
Srv.h
Here's the code in this header file:
...
typedef long DBINT;
typedef char DBCHAR;
typedef unsigned char DBBINARY;
typedef unsigned char DBBIT;
typedef double DBFLT8;
typedef struct srv_datetime
{ // Format for SRVDATETIME
long dtdays; // number of days since 1/1/1900
unsigned long dttime; // number 300th second since mid
} DBDATETIME;
typedef struct srv_money
{ // Format for SRVMONEY
long mnyhigh;
unsigned long mnylow;
} DBMONEY;
...
SRV_CONFIG* srv_getconfig( SRV_SERVER * server );
SRV_SERVER* srv_getserver( SRV_PROC * srvproc );
BOOL srv_got_attention( SRV_PROC * srvproc );
void* srv_eventdata( SRV_PROC * srvproc );
...
Thanks a lot,
SC
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement