Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Need to simplify sql commands
Message
From
24/01/2000 20:08:50
 
 
To
24/01/2000 18:22:06
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00320611
Message ID:
00321962
Views:
28
>>Yes. In fact that is the exact sytax I used and I was mystified when it didn't work.
>
>???????
>
>I'm stumped then, but I could swear I've used that exact approach before.

Ok I created a table called
TalentAppointments with 3 fields

dAppointment D
cProjectStatus C(10)
cTalentId C(9)

I've added 3 records.
{01/02/99}, "SUBMITTED", 1
{01/01/99}, "CALL BACK", 1
{01/02/99}, "AUDITION", 2

The select statement is as follows
SELECT MAX( dAppointment ), cTalentId, cProjectStatus ;
     FROM TalentAppointments ;
     GROUP BY 2
     HAVING cProjectStatus = "SUBMITTED"
The return set was empty.

I removed the HAVING clause and the return set was as follows.
{01/02/99}, "CALL BACK", "1"
{01/02/99}, "AUDITION", "1"

The first record should show "SUBMITTED" but its as if the value is randomly being pulled.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform