Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SET DATASESSION usage
Message
De
22/06/2000 11:58:22
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
SET DATASESSION usage
Divers
Thread ID:
00383218
Message ID:
00383218
Vues:
46
Hi all!

In VFP6's help about the SET DATASESSION command, there is this paragraph:

SET DATASESSION is typically used to debug forms, and should not be issued when a form is active.

However, I have this scenario: I have an object that talks to SQLServer (doing the SELECTs, INSERTs and so on). I created this object in my main prg because I want to share it for all forms - no need to have more than one connection. Forms use private datasessions, of course.

However, if, from a form, I call my SQL object to do a query, it executes the query in datasession 1 (default datasession), not in the form's datasession.

Is it acceptable in such a case to use the SET DATASESSION command in my SQL object so that the query will run in the form's datasession? This is what I'm currently doing and I haven't run into any problem, but does anyone ever has? Or is there a better way of doing this?

Thanks!
Sylvain Demers
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform