Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL 7.0 vs 8.0
Message
De
15/04/2003 16:35:44
 
 
À
15/04/2003 16:15:57
Henry Ravichander
RC Management Systems Inc.
Saskatchewan, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00777961
Message ID:
00778047
Vues:
14
Ravi,

>
>>Do you understand *why* the group clause is invalid?
>No. It ran in VFP6 and VFP7. So to me the "why" points to VFP8. Have used this code for a long time. Here is the one that gave the error:
>
>
SELECT Appointments.app_time, Appointments.app_date,;
>   Appointments.pat_last;
>  FROM appointments;
>  where appointments.app_date >= mquerydate .AND.;
>  appointments.app_date <= mquerydate + 8;
>  GROUP BY Appointments.app_time, Appointments.app_date;
>  ORDER BY Appointments.app_time, Appointments.app_date;
>  INTO CURSOR existingappoints nofilter
>

This has been discussed a lot recently; in case you missed them, below are some threads. In prior versions, you were allowed to select fields that were not in the group clause (or in an aggragate, such as SUM()).

In your example, you can't control which pat_last you get. For example, if you have three records with the same app_time, and if they have three different values for pat_last, VFP would (I believe) give you the pat_last for the first record it came accross.

The problem is, you really couldn't be sure you were getting the data you wanted for those fields. That's why they changed the behavior.

So I would SET ENGINE and set it back after the statement, only if you are convinced the code really works.

Re: Group by problem Thread #771194 Message #771302
Group by clause in vfp8 Thread #774269 Message #774269
Re: Data grouping with the reference of last transaction Thread #771821 Message #771832

>I am also concerned abou the second message "Data type is invalid for this property" and this message appears when I issue the Modify form MyForm command in the command window. Never used to happen with VFP 6 or 7.

I dunno about this one...
Steve Gibson
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform