Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Include deleted records
Message
From
01/11/2000 10:16:56
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
01/11/2000 10:05:44
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00436636
Message ID:
00436676
Views:
20
>In that case I will issue the following:
>
>SET DELETED OFF
>SELECT * FROM table2 INTO CURSOR table2_all
>
>Then issue my other select to bring across the deleted records.
>
>This should work OK, shouldn't it?
>
>THanks
>Kev

Kevin,
I'd do something like this :
select deleted() as delflag1, * from table1 into cursor t1 nofilter
select deleted() as delflag2, * from table2 into cursor t2 nofilter
select * ;
 from t1 ;
 left join t2 on t1.key = t2.key ;
 where !t1.delflag

* Or with one SQL :
select * ;
 from table1 ;
 left join table2 on table1.key = table2.key ;
 where table1.key not in (select table1.key from table1 where !deleted())
Cetin
Ç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