Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to arrange table columns in alphabetical order
Message
From
20/02/2001 14:10:11
Bob Lucas
The WordWare Agency
Alberta, Canada
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00477631
Message ID:
00477723
Views:
26
You can do a COPY STRUCTURE EXTENDED to get the table structure and then sort the field names and recreate the table using CREATE FROM. You will have to create another table that is physically ordered by the field names. Then you can append your data into this table and rename it to the original (after deleting the original).

If you build a routine to do this, you can easily do it with all of your tables. If they are free tables then it will work even better!


>>>I have some data dictionary software and some query maker software which both produce a list (either printed or online) of available fields for the clients to use. The software reads all my free tables and shows the column names in order. Well, some of the table have 100+ column and the columns are not in alphabetical order by name or even grouped together logically. As we add new column of course they get added to the end. The clients have not complained but I damn sure can not easily find a column when looking for it.
>>>
Previous
Reply
Map
View

Click here to load this message in the networking platform