Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select Statement Help?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00566073
Message ID:
00566081
Vues:
15
SELECT * ;
  FROM Meetings ;
  WHERE NOT isblock ;
UNION ;
SELECT  lastname,firstname, .F. As isblock, blockslot,schdate;
  FROM blocks ;
  INTO CURSOR mycursor
I have no idea what is relation between Meetings and blocks tables that's why this select doesn't take it in account.

>Meetings.dbf
>
>
>Meetings.dbf
>
>lastname,firstname,isblock,blockslot,schdate
>
>blocks.dbf
>
>lastname,firstname,blockslot,schdate
>
>
>
>In the first table individual patients are scheduled or a block is defined. If it is a block than isblock=.t..
>
>I need a query that returns a cursor of dist cases for a given date from both tables.
>
>Example:
>
>Meetings.dbf with 2 records
>LASTNAME   FIRSTNAME   ISBLOCK   BLOCKSLOT   SCHDATE
>=======================================================
>KELLY      KIRK         .F.        1234      10/07/2001
>BLOCK      BLOCK        .T.        1235      10/07/2001
>
>Blocks.dbf with 1 record
>
>LASTNAME   FIRSTNAME   ISBLOCK   BLOCKSLOT   SCHDATE
>=======================================================
>KELLY      ROGER        .F.        1235      10/07/2001
>
>
>Desired Results:
>
>LASTNAME   FIRSTNAME   ISBLOCK   BLOCKSLOT   SCHDATE
>=======================================================
>KELLY      KIRK         .F.        1234      10/07/2001
>KELLY      ROGER        .F.        1235      10/07/2001
>
>
>
>Any help greatly appreciated
>
>Kirk
--sb--
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform