Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Positioning fields when modifying table structure
Message
From
13/05/1998 11:20:58
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
13/05/1998 10:43:55
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00099041
Message ID:
00099056
Views:
22
>Hello:
>
>I'm modifying a table structure by adding new fields and changing some fields and need to position them in a certain position. I cannot
>use Copy Structure extended . My new fields are adding corectly but at the end of my table. Does anybody have any ideas on how to position
>my fields? Any suggestions would be greatly appreciated. Thank you

You could use afield()+create table from array.
use myTable
nFields = afield(aTableStruc)
nNewPos = 3
cNewFname = "test"
cNewFtype = "C"
nFlen = 10
nDec = 0
=ains(aTableStruc,nNewPos)
aTableStruc[nNewPos,1] = cFname
aTableStruc[nNewPos,2] = cFType
aTableStruc[nNewPos,3] = nFlen
aTableStruc[nNewPos,4] = nDec
for ix = 7 to 16
   aTableStruc[nNewPos,ix] = ""
endfor
create table myNewTable from array aTableStruc
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform