Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to select fields without hard-coding?
Message
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
How to select fields without hard-coding?
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01304667
Message ID:
01304667
Vues:
65
Good morning,

I need to create a routine of selecting (using SQL Select) only certain fields from a table/cursor. The fields that are to be selected should not be hard coded into the SQL Select. For example, if I could create an array where the fields would be stored, as e.g.:
local array aFlds[3]
aFlds[1]="myfld1"
aFlds[2]="myfld2"
aFlds[3]="myfld3"
If I could then use this array in the SQL select to select only these fields. Is something like this possible?

Any other suggestions?
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform