Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Problem opening views
Versions des environnements
Consider this code...
* In the load event of form1
SELECT 0
USE MyView
* In the load event of form2 (using same datatsession as form1)
SELECT 0
USE MyView
Because form1 and form2 share the same datasession, I would expect an error to be raised when opening MyView the second time, but it doesn't, the view is opened in the next available area with a single-letter alias which I do not know and have no control over.
If MyView was a .dbf file, I get the error "File is in use" which is what I would expect. As these forms have to share the same DS, and I don't know which form will be launched first, I guess the safe way is to always check if the view is open first (or always open a view with the ALIAS clause). But the question still remains - why doesn't the error occur with views?
Any help would be appreciated.
Alan
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