Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL - SELECT and IN Subquery
Message
From
01/09/2005 11:19:56
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01045811
Message ID:
01045853
Views:
25
Ok.. here is real code from application
		Select artikelweb.Iartnummer,;
			artikelweb.Hersteller,;
			artikelweb.wa_nummer,;
			artikelweb.warengrupp, ;
			artikelweb.art_bez1,;
			artikelweb.artikel_nr,;
			artikelweb.groupid2;
			FROM artikelweb ;
			WHERE  aktiv_teil and (Internet or into_Web) AND (Alltrim(Upper(artikelweb.Iartnummer)) ;
			 NOT In (Select Alltrim(Upper(artikelwebsort.Iartnummer)) From artikelwebsort Where artikelwebsort.nType=2 ));
			ORDER By wa_nummer,warengrupp;
			INTO Cursor __NotInList
First SQL
		Select artikelweb.Iartnummer,;
			artikelweb.Hersteller,;
			artikelweb.wa_nummer,;
			artikelweb.warengrupp, ;
			artikelweb.art_bez1,;
			artikelweb.artikel_nr,;
			artikelweb.groupid2;
			FROM artikelweb ;
			WHERE  aktiv_teil and (Internet or into_Web) INTO CURSOR __table1

Return 169 records...
SET FILTER TO wa_nummer="0001" - 4 records
Select Alltrim(Upper(artikelwebsort.Iartnummer)), wa_nummer From artikelwebsort Where artikelwebsort.nType=2 INTO CURSOR __table2

Return 1070 records
SET FILTER TO wa_nummer="0001" - 2 records..


Where is losted 2 records which present in ARTIKELWEB not not in ARTIKELWEBSORT ?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform