Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Passing a date to a SQL stored proc using SQLEXEC
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Passing a date to a SQL stored proc using SQLEXEC
Versions des environnements
Visual FoxPro:
VFP 7 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
01090805
Message ID:
01090805
Vues:
109
I am running SQL Server 2000 and am using SQLEXEC() to pull recordsets from SQL. I want to pass two date parameters from VFP7 to SQL using SQLEXEC but I don't get any data back. Here is my syntax on the VFP side:

nRetVal = SQLEXEC(nConn,"EXEC usp_StoredProc '"+ALLT(DTOC(dDate1))+"' '"+ALLT(DTOC(dDate2))+"'",'cursor1')

Within my SQL sp I have a @dDate1 DATETIME, @date2 DATETIME declared.

Do I need to somehow CAST the VFP dates to DATETIME?
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform