Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Need good practice suggestion
Message
 
 
À
23/10/2008 09:15:12
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Vista
Network:
Windows 2008 Server
Database:
MS SQL Server
Divers
Thread ID:
01356528
Message ID:
01356556
Vues:
31
>>>
>>>This error may indicate that you have SET EXCLUSIVE ON and Select tries to use some table, not open yet in the code. I would fix this problem, i.e. eliminate the error. TRY/CATCH is supposed to be used when error is more elusive, e.g. some network drive may exist or not, some import file is supposed to have specific format, etc.
>>
>>I don't think I have SET EXCLUSIVE ON in any part of my application. My suspicion is that the network or server sometimes has a delay in allowing files to be opened.
>
>Maybe, it is a good idea to open all needed tables without relying on implicit opening by SQL-Select?

Actually, this is what I used to do. But now I am converting the application to a 3-tier design with the purpose of using either VFP data or SQL Server. So now I am passing to the DA tier an expression that may need any number of tables to be opened. So unless the function in DA tier parses the expression and finds all tables that need to be opened, it is difficult to open the tables beforehand. I believe that by wrapping the macro in TRY/CATCH will eliminate run-time errors. Also, I think I need to include SET REPROCESS TO a large number of seconds.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform