Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL problems
Message
De
24/09/1998 08:16:51
 
 
À
23/09/1998 16:56:38
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00140068
Message ID:
00140294
Vues:
32
>Question #1:
>I have a form (in a multi-user app) that uses several views as the main source of data. I have a rotation system setup to switch the main data source between these views depending on what the user asks to see. Obviously these views all return the same fields. They just query for them based on different criteria.
>
>I created a view with a literal in the where clause to handle the difference in criteria. This is an example of the view query:
>
>
>Apparently you can't vary the FROM part of the query.
>
>So... Suggestion?
>

Why do you need to create the view? If you just execute the SQL statement, you can build it as a string and simply execute it... A lot more flex this way, I guess.

>Can I create views on the fly?

Dunno.

>Question #2:
>This app was originally created in VFP3 where there are no outer joins. We cheated and added records in each related table with a dummy id to allow the join to happen.
>
>We're now in VFP5... Now that Left Outer Joins are available should we use them? I've done some testing and it appears that our cheat is faster.

Then why not stick with it? Besides, that cheat is probably more portable.

HTH
Alexandre Nobre
Alpha Bytes Computer Corp.

Did you know that there are innocent people dying in East Timor?
It helps if you do...

I suppose you don't need glasses if you're able to read this line

Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform