Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Homer Simpson coding puzzle
Message
De
26/02/2001 00:33:05
 
 
À
25/02/2001 17:01:22
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00479329
Message ID:
00479384
Vues:
44
OK, OK --- Ya got me ... and Zahid had a good idea about placement of the options.

>>Hey all. Simple test of the "doh!" principle here: The question is 'What will end up being printed on the screen?' .. Yes, I know the answer - just testing y'all :-)
>>
>>And, no, it's not the GenPrimary() UDF
>>
>>
>>OPEN DATA foomeister
>>CREATE TABLE foo (pk C(30) PRIMARY KEY,amount N(10,2),quantity N(4,0))
>>INSERT INTO foo (pk,amount,quantity) VALUES (GenPrimary(),100.15,1)
>>SELECT * FROM foo WHERE amount > 200 INTO CURSOR foobaby
>>SELECT foobaby
>>DO CASE
>>CASE foobaby.amount = 0.00
>>  ?"No Sale"
>>CASE RECCOUNT('foobaby') = 0
>>  ?"No records"
>>CASE foobaby.amount <= 200
>>  ?"Small spender"
>>ENDCASE
>
>"No Sale"
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform