Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How may I change order of a field in a table ?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00439283
Message ID:
00439373
Vues:
16
>>I alredy know the command ALTER TABLE .... to modify a table. I'm able to add fields, but they are always added as the last field. I would like to know how to insert a field at the position I want or to only change the position of an existing field. Of course, I want to do this by programmation...

>About 3 months ago I had the similar problem and thread. I think, there is no way to change order of the fields rather than manually re-arrange them.
This is just an idea, but should work:
- Use AFIELDS()
- AINS() rows corrsponding to new fields.
- create a new table
- APPEND FROM exisitng table (fields with matching names should be mapped correctly)
- delete the current table
- and finally rename the new table.
censored.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform