Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Combine 5 tables to 1 cursor
Message
De
13/06/2018 04:57:50
 
 
À
12/06/2018 15:35:13
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Divers
Thread ID:
01660692
Message ID:
01660706
Vues:
55
>>>(( fields: Name, iemail, content, sendto, sendcc, sendbcc))
>>>John,11,Test,.t.,.f.,.f.
>>>Koen,11,Test,.t.,.f.,.f.
>>>Rob,11,Test,.f.,.t.,.f.
>>>Maria,11,Test,.f.,.t.,.f.
>>>Bill,11,Test,.f.,.f.,.t.
>>>Somebody to assist me?
>>
>>create UNION of all combinations of cursors 1+2 found in send cursors with dummy send fields an run update statements,
>>updates needed to allow distinct handling of UNION
>>
>Thomas,
>your solution 1 works OK for my first requirement and adapted a little bit with 3 extra fields which to be set .T. or .F. it also works for my second requirement.

That is the main thing ;-)
That said, instead of boolean fields in 2nd requirement I'd use integers: you have the cheap check of 0 or higher to get your current needs but also have a check with >1 for programming errors sending same mail twice via same send channel or adding all # to see how often same recipient received that specific mail ;-))

Filling those integers via SQL not really harder to code - perhaps a bit slower as more records need to be checked, but should not create a perf problem.

>I find your solution 1 better than 2 with updating.

I went at it from the base requirement of existing tables - also hinting, that my base tables would be different (the union of send-cursors as base table), which would allow to answer a greater range of questions thrown at the data directly ;-))
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform