Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Help with SQL statement
Message
 
 
À
23/09/1999 08:09:34
Bruce Covey
Home Depot Television
Atlanta, Georgie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00267805
Message ID:
00267936
Vues:
23
>SELECT iif(nvl(Checkinout.lflag,.F.),"Y","") as lflag,;
> Tapelib.ntapeid, Tapelib.ctitle, Tapelib.ddatep_a, Tapelib.cttyp,;
> Tapelib.ctrt, Projects.cproj_num, Projects.cproj_title,;
> Projects.cproducer, Projects.cclient, Tapelib.clanguage, Tapelib.cformat,;
> Tapelib.ccategory, Tapelib.lcc, Tapelib.mnotes, Tapelib.ctl_index;
> FROM rsrc!projects INNER JOIN rsrc!tapelib;
> LEFT OUTER JOIN rsrc!checkinout ;
> LEFT OUTER JOIN rsrc!featper ;
> ON Tapelib.ctl_index = Featper.ctl_index ;
> ON Tapelib.ctl_index = Checkinout.ctl_index ;
> ON Projects.cmaster_index = Tapelib.cmaster_index;
> WHERE &running; && I construct this interactively
> GROUP BY Tapelib.ntapeid;
> ORDER BY Tapelib.ntapeid;
> INTO CURSOR search
>

Let's go 1 step at a time. First, un-nest the JOINS:
FROM  rsrc!projects ;
    INNER JOIN rsrc!tapelib ;
       ON Projects.cmaster_index = Tapelib.cmaster_index ;
    LEFT OUTER JOIN rsrc!checkinout ;
       ON Tapelib.ctl_index = Checkinout.ctl_index ;
    LEFT OUTER JOIN rsrc!featper ;
      ON Tapelib.ctl_index = Featper.ctl_index...
You will no longer be able to use the View Designer. I have a script PRG file that I can run at any time to recreate any view. I also use Erik Moore's eView utility to generate all the code needed for existing views [including all the CursorSetProp and DBSetProp commands]. eView can be found in the Files section.

Second, in your IIF() statement, make sure the false value is a blank space [i.e., make sure this a space between your quotes].
Mark McCasland
Midlothian, TX USA
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform