Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Not getting all of the possible records?
Message
 
 
À
26/10/2002 16:25:39
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00715045
Message ID:
00715833
Vues:
11
Try
UNION ;
SELECT DISTINCT STR(0, 19) + TTOC(DATETIME(2000,01,01,12,00,00), 1) max_dt ;
FROM names ;
WHERE RECNO() = 1 ;
INTO CURSOR viewNames_Max
>Thanks Sergey, your help led me to a path that would work. What was required to work around the problem was a dumby record.
>
>SELECT STR(a.id, 19) + MAX(TTOC(a.effective_date, 1)) max_dt ;
>FROM names a ;
>GROUP BY a.id ;
>UNION ;
>SELECT DISTINCT STR(0, 19) + TTOC(DATETIME(2000,01,01,12,00,00), 1) max_dt ;
>FROM names a ;
>WHERE 1 = 1 ;
>INTO CURSOR viewNames_Max ;
>ORDER BY 1
>
>The first query pulls all of the valid records, the second creates the dumby record. Do you know of a way to create the record without using "WHERE 1 = 1" and "DISTINCT"?
>
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform