Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL-SELECT HELP
Message
From
23/01/2001 10:14:58
 
 
To
23/01/2001 10:05:36
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00467274
Message ID:
00467290
Views:
13
Hi!

Delete from TableEx where TableEx.IDNUMBER IN (Select TE.IDNUMBER from TableEx TE Where !empty(TE.CODE) )

You also can improve performance when you change last WHERE to "!(TE.CODE == ' ')", be sure to place correct number of spaces in the single quotes that should match to the width of field.

>Hi All,
>
>I would like to use SELECT command to search only in one table (DBF).
>Could anyone help me with some codes ?
>
>TableEx.dbf contained three fields :
>
>IDNUMBER DATE CODE
>
>11111 01/01/01
>11111 01/02/01 X
>11111 01/03/01
>11111 01/04/01
>22222 01/01/01
>22222 01/02/01
>22222 01/03/01
>22222 01/04/01
>33333 01/01/01
>33333 01/02/01
>33333 01/03/01 Y
>33333 01/04/01
>
>after used SELECT and DELETE, I should have only one IDNUMBER
>left in the TABLEEX.DBF means every IDNUMBER who had no blank CODE
>should be deleted from the table.
>
>22222 01/01/01
>22222 01/02/01
>22222 01/03/01
>22222 01/04/01
>
>Thanks in advance,
>Paul
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform