Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
View, Union & Multi-user problem
I have a view of the form:
Define View AView As ;
Select FieldA,... From Table1 Where &cWhere1 ;
Union Select FieldA,... From Table2 Where &cWhere2
Which works fine in normal circumstances.
But it doesn't always work properly in a multi-user environment.
If Table1 is in exclusive use by somebody else the view fails to open with expected errors that can be handled.
However, If Table2 is in exclusive use while Table1 is available then the view opens (with a NoData clause) without a pause and no errors. Calling Requery() on the view causes a long pause while Vfp tries to open Table2 but even though it can't it still returns 1 as if it were successfull. It returns no records.
So in the second case there doesn't seem to be any way to tell if the requery() is returning no records becuase none match the criteria or because Table2 is in exclusive use by somebody else.
Does anybody see what I'm missing or know of a workaround.
Thanks, Mars Feeney
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