Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SPT Syntax
Message
De
31/12/2008 16:55:54
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01370358
Message ID:
01370411
Vues:
24
Thanks.

So it's that simple, huh. My consultant is just going to plop the userid and password, make sure that the name of connection is correct (rlitepro10.dbo) and away we go. No gotchas that I need to worry about ahead of time?

>Looks OK to me so far from the quick glance. I would use TEXT/ENDTEXT for SQL commands, though, but this is cosmetics.
>
>>OK, well then can you help me on this for SQL Server 2005?
>>
>>>Yossi,
>>>
>>>I don't think there is SQL Server 2003 version. You probably meant SQL Server 2005.
>>>
>>>>Hi All:
>>>>
>>>>I have a client who has SQL Server enterprise 2003 version. He wants to go against the SQL Server database from within VFP.
>>>>
>>>>Since I know very little about SQL Server, I have asked a SQL Server expert to go onsite and help me. He, on the other hand, has no experience with VFP.
>>>>
>>>>I have prepared a program for him to try, based on SQL Server code supplied to me by my client, as follows. I am expecting my consultant to fill in the blanks such as userid and password:
>>>>
>>>>
>>>>LOCAL lcSQLString 
>>>>
>>>>lcSQLString = "UPDATE rlitepro10.dbo.icitem  " ;
>>>>	+ "set icitem.price2 = icpric.unitpr2,icitem.level2 = icpric.begqty2,icitem.price3 = 2* (icpric.unitpr2)-0.01  " ;
>>>>	+ "FROM rlitepro10.dbo.icitem icitem, rlitepro10.dbo.icpric icpric  " ;
>>>>	+ "WHERE icitem.item = icpric.item AND ((icpric.psched='SAL') AND (icpric.popt='I'))"
>>>>
>>>>
>>>>lnConnectionHandle = SQLCONNECT('rlitepro10.dbo','<userid>','<password>')
>>>>
>>>>IF !(lnConnectionHandle = -1)
>>>>	SQLEXEC(lnConnectionHandle , lcSQLString)
>>>>	
>>>>	SQLDISCONNECT(lnConnectionHandle )
>>>>	
>>>>ENDIF
>>>>
>>>>
>>>>Do I need to know anything else or add anything else to the program?
>>>>
>>>>Any help on this will be much appreciated.
>>>>
>>>>Thanks,
>>>>
>>>>Yossi
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform