>Hi All:
>
>I have a table from which I would like to traverse down thru the table and store the number from field1 in that table to a prg file. e.g
>. the prg file after numbers are stored would look like:
>
>111
>112
>113
>114 etc
>
By a PRG file, do you mean simply a text file, or do you need to insert the information into something that is actually going to be treated as running code? If the former, it's trivial; simply:
SELECT STR(FIELD1,3) FROM MyTable TO FILE MyOutputFile.PRG ORDER BY FIELD1
>I would also like to programatically insert each of the numbers form a prg file which will be stored as shown above, into a table that will be programatically created.
>
CREATE CURSOR MyCursor (FIELD1 I)
APPEND FROM MyOutputFile.PRG TYPE DELIMITED