Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Get all records except the latest
Message
From
30/10/2008 10:25:33
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01356683
Message ID:
01358354
Views:
25
This message has been marked as a message which has helped to the initial question of the thread.
I cannot get it into one sql statement but here is a foxpro solution for the Date1 case:

set enginebehavior 70

select pk, max(Date1) from mytable where Flag=1 group by fk into cursor ctemp

update mytable set Flag=0 where NOT pk in (select pk from ctemp)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform