Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Group by in a union clause error, (not the usual one)
Message
From
05/10/2005 13:00:45
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01056034
Message ID:
01056360
Views:
18
So I was right in thinking it would be * :)
Select * from Xtable t1 ;
   where id = ;
  (select min(id) from xtable t2 where t1.foreignkey = t2.foreignkey)
The implied grouping is perfectly legal (at least to SQL server and VFP versions I know)
However I don't use view designer at all and don't have an idea if it would accept or not (I explicitly add force clause to 'disable' designer).
Cetin

>The basic idea is to return the first item of every group of related items from a given table. So you need to determine which ones are first of a group, then get the entirety of those rows.
>
>
>I'll give your construction a try, I'm not sure if VFP 9 will accept the implied grouping but its a good idea.
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform